coverage-report

Code coverage report for All files

npmtest-openlayers (v0.0.1)

Code coverage report for All files

Statements: 6.56% (1529 / 23316)      Branches: 1.49% (157 / 10525)      Functions: 1.34% (49 / 3667)      Lines: 13.23% (945 / 7141)      Ignored: 26 statements, 1 function, 30 branches     

File Statements Branches Functions Lines
node-npmtest-openlayers/ 100% (153 / 153) 100% (126 / 126) 100% (28 / 28) 100% (153 / 153)
node-npmtest-openlayers/node_modules/openlayers/dist/ 5.9% (1013 / 17179) 0.13% (11 / 8754) 0.3% (8 / 2645) 42.73% (429 / 1004)
node-npmtest-openlayers/node_modules/openlayers/externs/ 11.63% (155 / 1333) 100% (0 / 0) 0% (0 / 293) 11.63% (155 / 1333)
node-npmtest-openlayers/node_modules/openlayers/src/ol/ 1.9% (77 / 4043) 0% (0 / 1435) 0% (0 / 595) 1.9% (77 / 4043)
node-npmtest-openlayers/node_modules/openlayers/tasks/ 23.3% (120 / 515) 11.11% (20 / 180) 13.13% (13 / 99) 23.3% (120 / 515)
node-npmtest-openlayers/node_modules/openlayers/transforms/ 11.83% (11 / 93) 0% (0 / 30) 0% (0 / 7) 11.83% (11 / 93)
Code coverage report for node-npmtest-openlayers/

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/

Statements: 100% (153 / 153)      Branches: 100% (126 / 126)      Functions: 100% (28 / 28)      Lines: 100% (153 / 153)      Ignored: 26 statements, 1 function, 30 branches     

All files » node-npmtest-openlayers/
File Statements Branches Functions Lines
example.js 100% (83 / 83) 100% (73 / 73) 100% (12 / 12) 100% (83 / 83)
lib.npmtest_openlayers.js 100% (16 / 16) 100% (14 / 14) 100% (3 / 3) 100% (16 / 16)
test.js 100% (54 / 54) 100% (39 / 39) 100% (13 / 13) 100% (54 / 54)
Code coverage report for node-npmtest-openlayers/example.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/example.js

Statements: 100% (83 / 83)      Branches: 100% (73 / 73)      Functions: 100% (12 / 12)      Lines: 100% (83 / 83)      Ignored: 26 statements, 1 function, 30 branches     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328                                                  2   2         2   2   2 2 2         1             2       2       2   2               1 2           2     2     2 2   1       2     1 1 1   1 1     1 1   1     1   2           1   1   1         1 2 2 3 3 3 3 1     3 3         3       1 3 1       1 1               1   1 1 1   1   1                                                                                                                                                                                       1 1                       1     6 6   1   2   1   2         1 1   1         1             1     1 1     1 1   1 1 1 1 1 1 1   1 1   1        
/*
example.js
 
quickstart example
 
instruction
    1. save this script as example.js
    2. run the shell command:
        $ npm install npmtest-openlayers && PORT=8081 node example.js
    3. play with the browser-demo on http://127.0.0.1:8081
*/
 
 
 
/* istanbul instrument in package npmtest_openlayers */
/*jslint
    bitwise: true,
    browser: true,
    maxerr: 8,
    maxlen: 96,
    node: true,
    nomen: true,
    regexp: true,
    stupid: true
*/
(function () {
    'use strict';
    var local;
 
 
 
    // run shared js-env code - pre-init
    (function () {
        // init local
        local = {};
        // init modeJs
        local.modeJs = (function () {
            try {
                return typeof navigator.userAgent === 'string' &&
                    typeof document.querySelector('body') === 'object' &&
                    typeof XMLHttpRequest.prototype.open === 'function' &&
                    'browser';
            } catch (errorCaughtBrowser) {
                return module.exports &&
                    typeof process.versions.node === 'string' &&
                    typeof require('http').createServer === 'function' &&
                    'node';
            }
        }());
        // init global
        local.global = local.modeJs === 'browser'
            ? window
            : global;
        // init utility2_rollup
        local = local.global.utility2_rollup || (local.modeJs === 'browser'
            ? local.global.utility2_npmtest_openlayers
            : global.utility2_moduleExports);
        // export local
        local.global.local = local;
    }());
    switch (local.modeJs) {
 
 
 
    // post-init
    // run browser js-env code - post-init
    /* istanbul ignore next */
    case 'browser':
        local.testRunBrowser = function (event) {
            Eif (!event || (event &&
                    event.currentTarget &&
                    event.currentTarget.className &&
                    event.currentTarget.className.includes &&
                    event.currentTarget.className.includes('onreset'))) {
                // reset output
                Array.from(
                    document.querySelectorAll('body > .resettable')
                ).forEach(function (element) {
                    switch (element.tagName) {
                    case 'INPUT':
                    case 'TEXTAREA':
                        element.value = '';
                        break;
                    default:
                        element.textContent = '';
                    }
                });
            }
            switch (event && event.currentTarget && event.currentTarget.id) {
            case 'testRunButton1':
                // show tests
                Eif (document.querySelector('#testReportDiv1').style.display === 'none') {
                    document.querySelector('#testReportDiv1').style.display = 'block';
                    document.querySelector('#testRunButton1').textContent =
                        'hide internal test';
                    local.modeTest = true;
                    local.testRunDefault(local);
                // hide tests
                } else {
                    document.querySelector('#testReportDiv1').style.display = 'none';
                    document.querySelector('#testRunButton1').textContent = 'run internal test';
                }
                break;
            // custom-case
            default:
                break;
            }
            Iif (document.querySelector('#inputTextareaEval1') && (!event || (event &&
                    event.currentTarget &&
                    event.currentTarget.className &&
                    event.currentTarget.className.includes &&
                    event.currentTarget.className.includes('oneval')))) {
                // try to eval input-code
                try {
                    /*jslint evil: true*/
                    eval(document.querySelector('#inputTextareaEval1').value);
                } catch (errorCaught) {
                    console.error(errorCaught);
                }
            }
        };
        // log stderr and stdout to #outputTextareaStdout1
        ['error', 'log'].forEach(function (key) {
            console[key + '_original'] = console[key];
            console[key] = function () {
                var element;
                console[key + '_original'].apply(console, arguments);
                element = document.querySelector('#outputTextareaStdout1');
                Iif (!element) {
                    return;
                }
                // append text to #outputTextareaStdout1
                element.value += Array.from(arguments).map(function (arg) {
                    return typeof arg === 'string'
                        ? arg
                        : JSON.stringify(arg, null, 4);
                }).join(' ') + '\n';
                // scroll textarea to bottom
                element.scrollTop = element.scrollHeight;
            };
        });
        // init event-handling
        ['change', 'click', 'keyup'].forEach(function (event) {
            Array.from(document.querySelectorAll('.on' + event)).forEach(function (element) {
                element.addEventListener(event, local.testRunBrowser);
            });
        });
        // run tests
        local.testRunBrowser();
        break;
 
 
 
    // run node js-env code - post-init
    /* istanbul ignore next */
    case 'node':
        // export local
        module.exports = local;
        // require modules
        local.fs = require('fs');
        local.http = require('http');
        local.url = require('url');
        // init assets
        local.assetsDict = local.assetsDict || {};
        /* jslint-ignore-begin */
        local.assetsDict['/assets.index.template.html'] = '\
<!doctype html>\n\
<html lang="en">\n\
<head>\n\
<meta charset="UTF-8">\n\
<meta name="viewport" content="width=device-width, initial-scale=1">\n\
<title>{{env.npm_package_name}} (v{{env.npm_package_version}})</title>\n\
<style>\n\
/*csslint\n\
    box-sizing: false,\n\
    universal-selector: false\n\
*/\n\
* {\n\
    box-sizing: border-box;\n\
}\n\
body {\n\
    background: #dde;\n\
    font-family: Arial, Helvetica, sans-serif;\n\
    margin: 2rem;\n\
}\n\
body > * {\n\
    margin-bottom: 1rem;\n\
}\n\
.utility2FooterDiv {\n\
    margin-top: 20px;\n\
    text-align: center;\n\
}\n\
</style>\n\
<style>\n\
/*csslint\n\
*/\n\
textarea {\n\
    font-family: monospace;\n\
    height: 10rem;\n\
    width: 100%;\n\
}\n\
textarea[readonly] {\n\
    background: #ddd;\n\
}\n\
</style>\n\
</head>\n\
<body>\n\
<!-- utility2-comment\n\
<div id="ajaxProgressDiv1" style="background: #d00; height: 2px; left: 0; margin: 0; padding: 0; position: fixed; top: 0; transition: background 0.5s, width 1.5s; width: 25%;"></div>\n\
utility2-comment -->\n\
<h1>\n\
<!-- utility2-comment\n\
    <a\n\
        {{#if env.npm_package_homepage}}\n\
        href="{{env.npm_package_homepage}}"\n\
        {{/if env.npm_package_homepage}}\n\
        target="_blank"\n\
    >\n\
utility2-comment -->\n\
        {{env.npm_package_name}} (v{{env.npm_package_version}})\n\
<!-- utility2-comment\n\
    </a>\n\
utility2-comment -->\n\
</h1>\n\
<h3>{{env.npm_package_description}}</h3>\n\
<!-- utility2-comment\n\
<h4><a download href="assets.app.js">download standalone app</a></h4>\n\
<button class="onclick onreset" id="testRunButton1">run internal test</button><br>\n\
<div id="testReportDiv1" style="display: none;"></div>\n\
utility2-comment -->\n\
\n\
\n\
\n\
<label>stderr and stdout</label>\n\
<textarea class="resettable" id="outputTextareaStdout1" readonly></textarea>\n\
<!-- utility2-comment\n\
{{#if isRollup}}\n\
<script src="assets.app.js"></script>\n\
{{#unless isRollup}}\n\
utility2-comment -->\n\
<script src="assets.utility2.rollup.js"></script>\n\
<script src="jsonp.utility2._stateInit?callback=window.utility2._stateInit"></script>\n\
<script src="assets.npmtest_openlayers.rollup.js"></script>\n\
<script src="assets.example.js"></script>\n\
<script src="assets.test.js"></script>\n\
<!-- utility2-comment\n\
{{/if isRollup}}\n\
utility2-comment -->\n\
<div class="utility2FooterDiv">\n\
    [ this app was created with\n\
    <a href="https://github.com/kaizhu256/node-utility2" target="_blank">utility2</a>\n\
    ]\n\
</div>\n\
</body>\n\
</html>\n\
';
        /* jslint-ignore-end */
        Iif (local.templateRender) {
            local.assetsDict['/'] = local.templateRender(
                local.assetsDict['/assets.index.template.html'],
                {
                    env: local.objectSetDefault(local.env, {
                        npm_package_description: 'the greatest app in the world!',
                        npm_package_name: 'my-app',
                        npm_package_nameAlias: 'my_app',
                        npm_package_version: '0.0.1'
                    })
                }
            );
        } else {
            local.assetsDict['/'] = local.assetsDict['/assets.index.template.html']
                .replace((/\{\{env\.(\w+?)\}\}/g), function (match0, match1) {
                    // jslint-hack
                    String(match0);
                    switch (match1) {
                    case 'npm_package_description':
                        return 'the greatest app in the world!';
                    case 'npm_package_name':
                        return 'my-app';
                    case 'npm_package_nameAlias':
                        return 'my_app';
                    case 'npm_package_version':
                        return '0.0.1';
                    }
                });
        }
        // run the cli
        Eif (local.global.utility2_rollup || module !== require.main) {
            break;
        }
        local.assetsDict['/assets.example.js'] =
            local.assetsDict['/assets.example.js'] ||
            local.fs.readFileSync(__filename, 'utf8');
        // bug-workaround - long $npm_package_buildCustomOrg
        /* jslint-ignore-begin */
        local.assetsDict['/assets.npmtest_openlayers.rollup.js'] =
            local.assetsDict['/assets.npmtest_openlayers.rollup.js'] ||
            local.fs.readFileSync(
                local.npmtest_openlayers.__dirname + '/lib.npmtest_openlayers.js',
                'utf8'
            ).replace((/^#!/), '//');
        /* jslint-ignore-end */
        local.assetsDict['/favicon.ico'] = local.assetsDict['/favicon.ico'] || '';
        // if $npm_config_timeout_exit exists,
        // then exit this process after $npm_config_timeout_exit ms
        if (Number(process.env.npm_config_timeout_exit)) {
            setTimeout(process.exit, Number(process.env.npm_config_timeout_exit));
        }
        // start server
        if (local.global.utility2_serverHttp1) {
            break;
        }
        process.env.PORT = process.env.PORT || '8081';
        console.error('server starting on port ' + process.env.PORT);
        local.http.createServer(function (request, response) {
            request.urlParsed = local.url.parse(request.url);
            if (local.assetsDict[request.urlParsed.pathname] !== undefined) {
                response.end(local.assetsDict[request.urlParsed.pathname]);
                return;
            }
            response.statusCode = 404;
            response.end();
        }).listen(process.env.PORT);
        break;
    }
}());
 
 
Code coverage report for node-npmtest-openlayers/lib.npmtest_openlayers.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/lib.npmtest_openlayers.js

Statements: 100% (16 / 16)      Branches: 100% (14 / 14)      Functions: 100% (3 / 3)      Lines: 100% (16 / 16)      Ignored: none     

All files » node-npmtest-openlayers/ » lib.npmtest_openlayers.js
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55                      2   2         2   2   2 2 2         1             2       2   2   2 1   1 1 1          
/* istanbul instrument in package npmtest_openlayers */
/*jslint
    bitwise: true,
    browser: true,
    maxerr: 8,
    maxlen: 96,
    node: true,
    nomen: true,
    regexp: true,
    stupid: true
*/
(function () {
    'use strict';
    var local;
 
 
 
    // run shared js-env code - pre-init
    (function () {
        // init local
        local = {};
        // init modeJs
        local.modeJs = (function () {
            try {
                return typeof navigator.userAgent === 'string' &&
                    typeof document.querySelector('body') === 'object' &&
                    typeof XMLHttpRequest.prototype.open === 'function' &&
                    'browser';
            } catch (errorCaughtBrowser) {
                return module.exports &&
                    typeof process.versions.node === 'string' &&
                    typeof require('http').createServer === 'function' &&
                    'node';
            }
        }());
        // init global
        local.global = local.modeJs === 'browser'
            ? window
            : global;
        // init utility2_rollup
        local = local.global.utility2_rollup || local;
        // init lib
        local.local = local.npmtest_openlayers = local;
        // init exports
        if (local.modeJs === 'browser') {
            local.global.utility2_npmtest_openlayers = local;
        } else {
            module.exports = local;
            module.exports.__dirname = __dirname;
            module.exports.module = module;
        }
    }());
}());
 
 
Code coverage report for node-npmtest-openlayers/test.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/test.js

Statements: 100% (54 / 54)      Branches: 100% (39 / 39)      Functions: 100% (13 / 13)      Lines: 100% (54 / 54)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197                      2   2         2   2   2 2 2         1             2     2     1       1     1   1     2           2 2   2           1           1           2 2   2           1             1       1     1             1             1 1     1             1 1 1 1 1 1     1         2 2     1             2 2     1             2 2     1             2 2     1             1 1       1 1        
/* istanbul instrument in package npmtest_openlayers */
/*jslint
    bitwise: true,
    browser: true,
    maxerr: 8,
    maxlen: 96,
    node: true,
    nomen: true,
    regexp: true,
    stupid: true
*/
(function () {
    'use strict';
    var local;
 
 
 
    // run shared js-env code - pre-init
    (function () {
        // init local
        local = {};
        // init modeJs
        local.modeJs = (function () {
            try {
                return typeof navigator.userAgent === 'string' &&
                    typeof document.querySelector('body') === 'object' &&
                    typeof XMLHttpRequest.prototype.open === 'function' &&
                    'browser';
            } catch (errorCaughtBrowser) {
                return module.exports &&
                    typeof process.versions.node === 'string' &&
                    typeof require('http').createServer === 'function' &&
                    'node';
            }
        }());
        // init global
        local.global = local.modeJs === 'browser'
            ? window
            : global;
        switch (local.modeJs) {
        // re-init local from window.local
        case 'browser':
            local = local.global.utility2.objectSetDefault(
                local.global.utility2_rollup || local.global.local,
                local.global.utility2
            );
            break;
        // re-init local from example.js
        case 'node':
            local = (local.global.utility2_rollup || require('utility2'))
                .requireExampleJsFromReadme();
            break;
        }
        // export local
        local.global.local = local;
    }());
 
 
 
    // run shared js-env code - function
    (function () {
        return;
    }());
    switch (local.modeJs) {
 
 
 
    // run browser js-env code - function
    case 'browser':
        break;
 
 
 
    // run node js-env code - function
    case 'node':
        break;
    }
 
 
 
    // run shared js-env code - post-init
    (function () {
        return;
    }());
    switch (local.modeJs) {
 
 
 
    // run browser js-env code - post-init
    case 'browser':
        local.testCase_browser_nullCase = local.testCase_browser_nullCase || function (
            options,
            onError
        ) {
        /*
         * this function will test browsers's null-case handling-behavior-behavior
         */
            onError(null, options);
        };
 
        // run tests
        local.nop(local.modeTest &&
            document.querySelector('#testRunButton1') &&
            document.querySelector('#testRunButton1').click());
        break;
 
 
 
    // run node js-env code - post-init
    /* istanbul ignore next */
    case 'node':
        local.testCase_buildApidoc_default = local.testCase_buildApidoc_default || function (
            options,
            onError
        ) {
        /*
         * this function will test buildApidoc's default handling-behavior-behavior
         */
            options = { modulePathList: module.paths };
            local.buildApidoc(options, onError);
        };
 
        local.testCase_buildApp_default = local.testCase_buildApp_default || function (
            options,
            onError
        ) {
        /*
         * this function will test buildApp's default handling-behavior-behavior
         */
            local.testCase_buildReadme_default(options, local.onErrorThrow);
            local.testCase_buildLib_default(options, local.onErrorThrow);
            local.testCase_buildTest_default(options, local.onErrorThrow);
            local.testCase_buildCustomOrg_default(options, local.onErrorThrow);
            options = [];
            local.buildApp(options, onError);
        };
 
        local.testCase_buildCustomOrg_default = local.testCase_buildCustomOrg_default ||
            function (options, onError) {
            /*
             * this function will test buildCustomOrg's default handling-behavior
             */
                options = {};
                local.buildCustomOrg(options, onError);
            };
 
        local.testCase_buildLib_default = local.testCase_buildLib_default || function (
            options,
            onError
        ) {
        /*
         * this function will test buildLib's default handling-behavior
         */
            options = {};
            local.buildLib(options, onError);
        };
 
        local.testCase_buildReadme_default = local.testCase_buildReadme_default || function (
            options,
            onError
        ) {
        /*
         * this function will test buildReadme's default handling-behavior-behavior
         */
            options = {};
            local.buildReadme(options, onError);
        };
 
        local.testCase_buildTest_default = local.testCase_buildTest_default || function (
            options,
            onError
        ) {
        /*
         * this function will test buildTest's default handling-behavior
         */
            options = {};
            local.buildTest(options, onError);
        };
 
        local.testCase_webpage_default = local.testCase_webpage_default || function (
            options,
            onError
        ) {
        /*
         * this function will test webpage's default handling-behavior
         */
            options = { modeCoverageMerge: true, url: local.serverLocalHost + '?modeTest=1' };
            local.browserTest(options, onError);
        };
 
        // run test-server
        local.testRunServer(local);
        break;
    }
}());
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/dist/

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/dist/

Statements: 5.9% (1013 / 17179)      Branches: 0.13% (11 / 8754)      Functions: 0.3% (8 / 2645)      Lines: 42.73% (429 / 1004)      Ignored: none     

All files » node-npmtest-openlayers/node_modules/openlayers/dist/
File Statements Branches Functions Lines
ol.js 5.9% (1013 / 17179) 0.13% (11 / 8754) 0.3% (8 / 2645) 42.73% (429 / 1004)
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/dist/ol.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/dist/ol.js

Statements: 5.9% (1013 / 17179)      Branches: 0.13% (11 / 8754)      Functions: 0.3% (8 / 2645)      Lines: 42.73% (429 / 1004)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022      2 2 2             2 2 1 4 1 1 1 1 1 1 2           2 2 2 1 1 1 1 1   1 1 1 1 1 1 1 1 1 1 1   1   1 1     1     1 1   1   1       1 1 1 1 1   1   1 1 1 1 1         1 1 1 1 1   1 1 1 1 1 1 1   1 1 1 1 1 1 1 1 1   1   1 1 1   1       1 1 1 1       1 1 1 1 1 1 1 1 1 1 1 1 1 1   1 1 1 1 1 1 1 1     1 1 1 1 1 1 1 1 1 1         1 1         1 1   1   1 1     1           1   1 1 1 1   1 1 1 1 1     1         1 1 1 1     1   1         1   1 1 1 1 1 1 1 1 1             1 1 1 1 1 1   1   1 1 1 1 1 1 1 1             1   1   1         1 1   1 1 1         1                                 1     1       1 1 1 1       1 1 1 1 1 1   1     1 1   1     1         1   1 1 1 1   1 1 1 1 1 1 1 1 1 1   1   1   1   1       1 1     1 1 1       1 1     1         1 1 1               1 1               1                         1         1 1 1         1 1 1 1     1 1     1   1   1   1             1   1     1 1 1 1 1 1 1 1 1                         1 1 1 1 1 1 1             1     1     1 1     1 1 1 1   1 1   1 1   1     1 1 1 1 1   1   1   1   1       1 1               1 1     1 1 1 1     1 1 1             1   1       1       1 1 1 1 1       1 1 1   1 1 1 1 1         1     1 1     1 1           1         1 1   1   1 1 1 1 1 1     1       1 1 1 1   1     1 1 1 1 1 1 1 1         1   1 1 1 1 1 1   1 1 1 1 1 1 1 1   1       1 1   1 1 1 1 1         1   1   1           1 1 1 1 1 1     1   1 1 1     1   1   1 1   1   1 1   1   1       1         1 1 1         1 1     1 1 1 1 1   1   1   1 1       1 1 1 1 1 1     1   1 1       1 1 1 1 1       1       1 1   1     1 1   1     1   1 1       1 1   1 1 1 1 1   1 1   1   1 1                                                                                                                                                                                                                                                                                                                                                                                                                                                
// OpenLayers. See https://openlayers.org/
// License: https://raw.githubusercontent.com/openlayers/openlayers/master/LICENSE.md
// Version: v4.1.0
;(function (root, factory) {
  Eif (typeof exports === "object") {
    module.exports = factory();
  } else if (typeof define === "function" && define.amd) {
    define([], factory);
  } else {
    root.ol = factory();
  }
}(this, function () {
  var OPENLAYERS = {};
  var k,ba=this;function t(a,b){var c=OPENLAYERS,d=a.split("."),c=c||ba;d[0]in c||!c.execScript||c.execScript("var "+d[0]);for(var e;d.length&&(e=d.shift());)d.length||void 0===b?c[e]&&Object.prototype.hasOwnProperty.call(c,e)?c=c[e]:c=c[e]={}:c[e]=b};var ca,da;function ea(a,b){return a>b?1:a<b?-1:0}function fa(a,b){return 0<=a.indexOf(b)}function ga(a,b,c){var d=a.length;if(a[0]<=b)return 0;if(!(b<=a[d-1]))if(0<c)for(c=1;c<d;++c){if(a[c]<b)return c-1}else if(0>c)for(c=1;c<d;++c){if(a[c]<=b)return c}else for(c=1;c<d;++c){if(a[c]==b)return c;if(a[c]<b)return a[c-1]-b<b-a[c]?c-1:c}return d-1}function ha(a,b){var c,d=Array.isArray(b)?b:[b],e=d.length;for(c=0;c<e;c++)a[a.length]=d[c]}
function ia(a,b){for(var c=a.length>>>0,d,e=0;e<c;e++)if(d=a[e],b(d,e,a))return d;return null}function ja(a,b){var c=a.length;if(c!==b.length)return!1;for(var d=0;d<c;d++)if(a[d]!==b[d])return!1;return!0}function ka(a){var b=la,c=a.length,d=Array(a.length),e;for(e=0;e<c;e++)d[e]={index:e,value:a[e]};d.sort(function(a,c){return b(a.value,c.value)||a.index-c.index});for(e=0;e<a.length;e++)a[e]=d[e].value}function ma(a,b){var c;return a.every(function(d,e){c=e;return!b(d,e,a)})?-1:c}
function na(a,b){var c=b||ea;return a.every(function(b,e){if(!e)return!0;var d=c(a[e-1],b);return!(0<d||0===d)})};function u(a,b){a.prototype=Object.create(b.prototype);a.prototype.constructor=a}function oa(){}function w(a){return a.Lo||(a.Lo=++pa)}var pa=0;function qa(a){this.message="Assertion failed. See https://openlayers.org/en/v4.1.0/doc/errors/#"+a+" for details.";this.code=a;this.name="AssertionError"}u(qa,Error);function sa(a,b){if(!a)throw new qa(b);};function ta(a,b,c,d){this.da=a;this.ba=b;this.ga=c;this.ja=d}function ua(a,b,c){return a.da<=b&&b<=a.ba&&a.ga<=c&&c<=a.ja}function va(a,b){return a.da==b.da&&a.ga==b.ga&&a.ba==b.ba&&a.ja==b.ja}function wa(a,b){return a.da<=b.ba&&a.ba>=b.da&&a.ga<=b.ja&&a.ja>=b.ga};function xa(a,b,c){return Math.min(Math.max(a,b),c)}var ya=function(){var a;"cosh"in Math?a=Math.cosh:a=function(a){a=Math.exp(a);return(a+1/a)/2};return a}();function za(a){sa(0<a,29);return Math.pow(2,Math.ceil(Math.log(a)/Math.LN2))}function Aa(a,b,c,d,e,f){var g=e-c,h=f-d;if(g||h){var l=((a-c)*g+(b-d)*h)/(g*g+h*h);1<l?(c=e,d=f):0<l&&(c+=g*l,d+=h*l)}return Ba(a,b,c,d)}function Ba(a,b,c,d){a=c-a;b=d-b;return a*a+b*b}function Ca(a){return a*Math.PI/180}
function Da(a,b){var c=a%b;return 0>c*b?c+b:c}function Ea(a,b,c){return a+c*(b-a)};function Fa(a,b,c){void 0===c&&(c=[0,0]);c[0]=a[0]+2*b;c[1]=a[1]+2*b;return c}function Ga(a,b,c){void 0===c&&(c=[0,0]);c[0]=a[0]*b+.5|0;c[1]=a[1]*b+.5|0;return c}function Ha(a,b){if(Array.isArray(a))return a;void 0===b?b=[a,a]:b[0]=b[1]=a;return b};function Ia(a){for(var b=Ja(),c=0,d=a.length;c<d;++c)La(b,a[c]);return b}function Ma(a,b,c){return c?(c[0]=a[0]-b,c[1]=a[1]-b,c[2]=a[2]+b,c[3]=a[3]+b,c):[a[0]-b,a[1]-b,a[2]+b,a[3]+b]}function Oa(a,b){return b?(b[0]=a[0],b[1]=a[1],b[2]=a[2],b[3]=a[3],b):a.slice()}function Pa(a,b,c){b=b<a[0]?a[0]-b:a[2]<b?b-a[2]:0;a=c<a[1]?a[1]-c:a[3]<c?c-a[3]:0;return b*b+a*a}function Qa(a,b){return Sa(a,b[0],b[1])}function Ua(a,b){return a[0]<=b[0]&&b[2]<=a[2]&&a[1]<=b[1]&&b[3]<=a[3]}
function Sa(a,b,c){return a[0]<=b&&b<=a[2]&&a[1]<=c&&c<=a[3]}function Va(a,b){var c=a[1],d=a[2],e=a[3],f=b[0],g=b[1],h=0;f<a[0]?h|=16:f>d&&(h|=4);g<c?h|=8:g>e&&(h|=2);h||(h=1);return h}function Ja(){return[Infinity,Infinity,-Infinity,-Infinity]}function Wa(a,b,c,d,e){return e?(e[0]=a,e[1]=b,e[2]=c,e[3]=d,e):[a,b,c,d]}function Xa(a,b){var c=a[0],d=a[1];return Wa(c,d,c,d,b)}function Ya(a,b,c,d,e){e=Wa(Infinity,Infinity,-Infinity,-Infinity,e);return Za(e,a,b,c,d)}
function $a(a,b){return a[0]==b[0]&&a[2]==b[2]&&a[1]==b[1]&&a[3]==b[3]}function ab(a,b){b[0]<a[0]&&(a[0]=b[0]);b[2]>a[2]&&(a[2]=b[2]);b[1]<a[1]&&(a[1]=b[1]);b[3]>a[3]&&(a[3]=b[3]);return a}function La(a,b){b[0]<a[0]&&(a[0]=b[0]);b[0]>a[2]&&(a[2]=b[0]);b[1]<a[1]&&(a[1]=b[1]);b[1]>a[3]&&(a[3]=b[1])}function Za(a,b,c,d,e){for(;c<d;c+=e){var f=a,g=b[c],h=b[c+1];f[0]=Math.min(f[0],g);f[1]=Math.min(f[1],h);f[2]=Math.max(f[2],g);f[3]=Math.max(f[3],h)}return a}
function bb(a,b,c){var d;return(d=b.call(c,cb(a)))||(d=b.call(c,db(a)))||(d=b.call(c,eb(a)))?d:(d=b.call(c,fb(a)))?d:!1}function gb(a){var b=0;hb(a)||(b=ib(a)*jb(a));return b}function cb(a){return[a[0],a[1]]}function db(a){return[a[2],a[1]]}function kb(a){return[(a[0]+a[2])/2,(a[1]+a[3])/2]}
function lb(a,b,c,d,e){var f=b*d[0]/2;d=b*d[1]/2;b=Math.cos(c);var g=Math.sin(c);c=f*b;f*=g;b*=d;var h=d*g,l=a[0],m=a[1];a=l-c+h;d=l-c-h;g=l+c-h;c=l+c+h;var h=m-f-b,l=m-f+b,n=m+f+b,f=m+f-b;return Wa(Math.min(a,d,g,c),Math.min(h,l,n,f),Math.max(a,d,g,c),Math.max(h,l,n,f),e)}function jb(a){return a[3]-a[1]}function mb(a,b,c){c=c?c:Ja();nb(a,b)&&(c[0]=a[0]>b[0]?a[0]:b[0],c[1]=a[1]>b[1]?a[1]:b[1],c[2]=a[2]<b[2]?a[2]:b[2],c[3]=a[3]<b[3]?a[3]:b[3]);return c}function fb(a){return[a[0],a[3]]}
function eb(a){return[a[2],a[3]]}function ib(a){return a[2]-a[0]}function nb(a,b){return a[0]<=b[2]&&a[2]>=b[0]&&a[1]<=b[3]&&a[3]>=b[1]}function hb(a){return a[2]<a[0]||a[3]<a[1]}function ob(a,b){var c=(a[2]-a[0])/2*(b-1),d=(a[3]-a[1])/2*(b-1);a[0]-=c;a[2]+=c;a[1]-=d;a[3]+=d}
function pb(a,b,c){a=[a[0],a[1],a[0],a[3],a[2],a[1],a[2],a[3]];b(a,a,2);var d=[a[0],a[2],a[4],a[6]],e=[a[1],a[3],a[5],a[7]];b=Math.min.apply(null,d);a=Math.min.apply(null,e);d=Math.max.apply(null,d);e=Math.max.apply(null,e);return Wa(b,a,d,e,c)};var qb="function"===typeof Object.assign?Object.assign:function(a,b){if(!a||null===a)throw new TypeError("Cannot convert undefined or null to object");for(var c=Object(a),d=1,e=arguments.length;d<e;++d){var f=arguments[d];if(void 0!==f&&null!==f)for(var g in f)f.hasOwnProperty(g)&&(c[g]=f[g])}return c};function rb(a){for(var b in a)delete a[b]}function sb(a){var b=[],c;for(c in a)b.push(a[c]);return b}function tb(a){for(var b in a)return!1;return!b};/*
 
 Latitude/longitude spherical geodesy formulae taken from
 http://www.movable-type.co.uk/scripts/latlong.html
 Licensed under CC-BY-3.0.
*/
function ub(a){this.radius=a}ub.prototype.a=function(a){for(var b=0,c=a.length,d=a[c-1][0],e=a[c-1][1],f=0;f<c;f++)var g=a[f][0],h=a[f][1],b=b+Ca(g-d)*(2+Math.sin(Ca(e))+Math.sin(Ca(h))),d=g,e=h;return b*this.radius*this.radius/2};ub.prototype.b=function(a,b){var c=Ca(a[1]),d=Ca(b[1]),e=(d-c)/2,f=Ca(b[0]-a[0])/2,c=Math.sin(e)*Math.sin(e)+Math.sin(f)*Math.sin(f)*Math.cos(c)*Math.cos(d);return 2*this.radius*Math.atan2(Math.sqrt(c),Math.sqrt(1-c))};
ub.prototype.offset=function(a,b,c){var d=Ca(a[1]);b/=this.radius;var e=Math.asin(Math.sin(d)*Math.cos(b)+Math.cos(d)*Math.sin(b)*Math.cos(c));return[180*(Ca(a[0])+Math.atan2(Math.sin(c)*Math.sin(b)*Math.cos(d),Math.cos(b)-Math.sin(d)*Math.sin(e)))/Math.PI,180*e/Math.PI]};var vb=new ub(6370997);var xb={};xb.degrees=2*Math.PI*vb.radius/360;xb.ft=.3048;xb.m=1;xb["us-ft"]=1200/3937;var yb=null;function zb(a){this.nb=a.code;this.i=a.units;this.c=void 0!==a.extent?a.extent:null;this.f=void 0!==a.worldExtent?a.worldExtent:null;this.b=void 0!==a.axisOrientation?a.axisOrientation:"enu";this.g=void 0!==a.global?a.global:!1;this.a=!(!this.g||!this.c);this.l=a.getPointResolution;this.j=null;this.o=a.metersPerUnit;var b=a.code,c=yb||window.proj4;"function"==typeof c&&(b=c.defs(b),void 0!==b&&(void 0!==b.axis&&void 0===a.axisOrientation&&(this.b=b.axis),void 0===a.metersPerUnit&&(this.o=b.to_meter),
void 0===a.units&&(this.i=b.units)))}k=zb.prototype;k.Fk=function(){return this.nb};k.D=function(){return this.c};k.Kb=function(){return this.i};k.uc=function(){return this.o||xb[this.i]};k.ol=function(){return this.f};k.Zl=function(){return this.g};k.Qp=function(a){this.g=a;this.a=!(!a||!this.c)};k.Mn=function(a){this.c=a;this.a=!(!this.g||!a)};k.$p=function(a){this.f=a};k.Pp=function(a){this.l=a};function Ab(a){zb.call(this,{code:a,units:"m",extent:Bb,global:!0,worldExtent:Cb,getPointResolution:function(a,c){return a/ya(c[1]/6378137)}})}u(Ab,zb);var Db=6378137*Math.PI,Bb=[-Db,-Db,Db,Db],Cb=[-180,-85,180,85],Eb="EPSG:3857 EPSG:102100 EPSG:102113 EPSG:900913 urn:ogc:def:crs:EPSG:6.18:3:3857 urn:ogc:def:crs:EPSG::3857 http://www.opengis.net/gml/srs/epsg.xml#3857".split(" ").map(function(a){return new Ab(a)});
function Fb(a,b,c){var d=a.length;c=1<c?c:2;void 0===b&&(2<c?b=a.slice():b=Array(d));for(var e=0;e<d;e+=c){b[e]=Db*a[e]/180;var f=6378137*Math.log(Math.tan(Math.PI*(a[e+1]+90)/360));f>Db?f=Db:f<-Db&&(f=-Db);b[e+1]=f}return b}function Gb(a,b,c){var d=a.length;c=1<c?c:2;void 0===b&&(2<c?b=a.slice():b=Array(d));for(var e=0;e<d;e+=c)b[e]=180*a[e]/Db,b[e+1]=360*Math.atan(Math.exp(a[e+1]/6378137))/Math.PI-90;return b};var Hb=new ub(6378137);function Ib(a,b){zb.call(this,{code:a,units:"degrees",extent:Jb,axisOrientation:b,global:!0,metersPerUnit:Kb,worldExtent:Jb})}u(Ib,zb);var Jb=[-180,-90,180,90],Kb=Math.PI*Hb.radius/180,Lb=[new Ib("CRS:84"),new Ib("EPSG:4326","neu"),new Ib("urn:ogc:def:crs:EPSG::4326","neu"),new Ib("urn:ogc:def:crs:EPSG:6.6:4326","neu"),new Ib("urn:ogc:def:crs:OGC:1.3:CRS84"),new Ib("urn:ogc:def:crs:OGC:2:84"),new Ib("http://www.opengis.net/gml/srs/epsg.xml#4326","neu"),new Ib("urn:x-ogc:def:crs:EPSG:4326","neu")];var Mb={};var Nb={};function Ob(a,b,c){a=a.nb;b=b.nb;a in Nb||(Nb[a]={});Nb[a][b]=c}function Qb(a,b){var c;a in Nb&&b in Nb[a]&&(c=Nb[a][b]);return c};function Rb(a,b,c){var d=a.l;d?b=d(b,c):"degrees"!=a.Kb()&&(d=Sb(a,Tb("EPSG:4326")),b=[c[0]-b/2,c[1],c[0]+b/2,c[1],c[0],c[1]-b/2,c[0],c[1]+b/2],b=d(b,b,2),b=(vb.b(b.slice(0,2),b.slice(2,4))+vb.b(b.slice(4,6),b.slice(6,8)))/2,a=a.uc(),void 0!==a&&(b/=a));return b}function Ub(a){Vb(a);a.forEach(function(b){a.forEach(function(a){b!==a&&Ob(b,a,Wb)})})}function Xb(){Lb.forEach(function(a){Eb.forEach(function(b){Ob(a,b,Fb);Ob(b,a,Gb)})})}function Yb(a){Mb[a.nb]=a;Ob(a,a,Wb)}
function Vb(a){var b=[];a.forEach(function(a){b.push(Yb(a))})}function Zb(a){return a?"string"===typeof a?Tb(a):a:Tb("EPSG:3857")}function $b(a,b,c,d){a=Tb(a);b=Tb(b);Ob(a,b,ac(c));Ob(b,a,ac(d))}function ac(a){return function(b,c,d){var e=b.length;d=void 0!==d?d:2;c=void 0!==c?c:Array(e);var f,g;for(g=0;g<e;g+=d)for(f=a([b[g],b[g+1]]),c[g]=f[0],c[g+1]=f[1],f=d-1;2<=f;--f)c[g+f]=b[g+f];return c}}
function Tb(a){var b=null;if(a instanceof zb)b=a;else if("string"===typeof a){var b=Mb[a]||null,c=yb||window.proj4;b||"function"!=typeof c||void 0===c.defs(a)||(b=new zb({code:a}),Yb(b))}return b}function bc(a,b){if(a===b)return!0;var c=a.Kb()===b.Kb();return a.nb===b.nb?c:Sb(a,b)===Wb&&c}function dc(a,b){var c=Tb(a),d=Tb(b);return Sb(c,d)}
function Sb(a,b){var c=a.nb,d=b.nb,e=Qb(c,d);if(!e){var f=yb||window.proj4;if("function"==typeof f){var g=f.defs(c),h=f.defs(d);void 0!==g&&void 0!==h&&(g===h?Ub([b,a]):(e=f(d,c),$b(b,a,e.forward,e.inverse)),e=Qb(c,d))}}e||(e=ec);return e}function ec(a,b){if(void 0!==b&&a!==b){for(var c=0,d=a.length;c<d;++c)b[c]=a[c];a=b}return a}function Wb(a,b){var c;if(void 0!==b){c=0;for(var d=a.length;c<d;++c)b[c]=a[c];c=b}else c=a.slice();return c}function fc(a,b,c){return dc(b,c)(a,void 0,a.length)}
function gc(a,b,c){b=dc(b,c);return pb(a,b)}function hc(){Ub(Eb);Ub(Lb);Xb()}hc();function ic(a,b,c,d){return void 0!==d?(d[0]=a,d[1]=b,d[2]=c,d):[a,b,c]}function jc(a){var b=a[0],c=Array(b),d=1<<b-1,e,f;for(e=0;e<b;++e)f=48,a[1]&d&&(f+=1),a[2]&d&&(f+=2),c[e]=String.fromCharCode(f),d>>=1;return c.join("")};function kc(a){this.minZoom=void 0!==a.minZoom?a.minZoom:0;this.b=a.resolutions;sa(na(this.b,function(a,b){return b-a}),17);this.maxZoom=this.b.length-1;this.g=void 0!==a.origin?a.origin:null;this.c=null;void 0!==a.origins&&(this.c=a.origins,sa(this.c.length==this.b.length,20));var b=a.extent;void 0===b||this.g||this.c||(this.g=fb(b));sa(!this.g&&this.c||this.g&&!this.c,18);this.i=null;void 0!==a.tileSizes&&(this.i=a.tileSizes,sa(this.i.length==this.b.length,19));this.f=void 0!==a.tileSize?a.tileSize:
this.i?null:256;sa(!this.f&&this.i||this.f&&!this.i,22);this.u=void 0!==b?b:null;this.a=null;this.j=[0,0];void 0!==a.sizes?this.a=a.sizes.map(function(a){return new ta(Math.min(0,a[0]),Math.max(a[0]-1,-1),Math.min(0,a[1]),Math.max(a[1]-1,-1))},this):b&&lc(this,b)}var mc=[0,0,0];k=kc.prototype;k.mh=function(a,b,c){a=nc(this,a,b);for(var d=a.da,e=a.ba;d<=e;++d)for(var f=a.ga,g=a.ja;f<=g;++f)c([b,d,f])};
function oc(a,b,c,d,e){e=a.Ua(b,e);for(b=b[0]-1;b>=a.minZoom;){if(c.call(null,b,nc(a,e,b,d)))return!0;--b}return!1}k.D=function(){return this.u};k.Ni=function(){return this.maxZoom};k.Oi=function(){return this.minZoom};k.Uc=function(a){return this.g?this.g:this.c[a]};k.La=function(a){return this.b[a]};k.Pi=function(){return this.b};function pc(a,b,c,d){return b[0]<a.maxZoom?(d=a.Ua(b,d),nc(a,d,b[0]+1,c)):null}
function qc(a,b,c,d){rc(a,b[0],b[1],c,!1,mc);var e=mc[1],f=mc[2];rc(a,b[2],b[3],c,!0,mc);a=mc[1];b=mc[2];void 0!==d?(d.da=e,d.ba=a,d.ga=f,d.ja=b):d=new ta(e,a,f,b);return d}function nc(a,b,c,d){return qc(a,b,a.La(c),d)}function sc(a,b){var c=a.Uc(b[0]),d=a.La(b[0]),e=Ha(a.eb(b[0]),a.j);return[c[0]+(b[1]+.5)*e[0]*d,c[1]+(b[2]+.5)*e[1]*d]}k.Ua=function(a,b){var c=this.Uc(a[0]),d=this.La(a[0]),e=Ha(this.eb(a[0]),this.j),f=c[0]+a[1]*e[0]*d,c=c[1]+a[2]*e[1]*d;return Wa(f,c,f+e[0]*d,c+e[1]*d,b)};
k.Ae=function(a,b,c){return rc(this,a[0],a[1],b,!1,c)};function rc(a,b,c,d,e,f){var g=a.Qc(d),h=d/a.La(g),l=a.Uc(g);a=Ha(a.eb(g),a.j);b=h*Math.floor((b-l[0])/d+(e?.5:0))/a[0];c=h*Math.floor((c-l[1])/d+(e?0:.5))/a[1];e?(b=Math.ceil(b)-1,c=Math.ceil(c)-1):(b=Math.floor(b),c=Math.floor(c));return ic(g,b,c,f)}k.Xf=function(a,b,c){return rc(this,a[0],a[1],this.La(b),!1,c)};k.eb=function(a){return this.f?this.f:this.i[a]};k.Qc=function(a,b){return xa(ga(this.b,a,b||0),this.minZoom,this.maxZoom)};
function lc(a,b){for(var c=a.b.length,d=Array(c),e=a.minZoom;e<c;++e)d[e]=nc(a,b,e);a.a=d};function tc(a){var b=a.j;if(!b){var b=uc(a),c=vc(b,void 0,void 0),b=new kc({extent:b,origin:fb(b),resolutions:c,tileSize:void 0});a.j=b}return b}function wc(a){var b={};qb(b,a?a:{});void 0===b.extent&&(b.extent=Tb("EPSG:3857").D());b.resolutions=vc(b.extent,b.maxZoom,b.tileSize);delete b.maxZoom;return new kc(b)}function vc(a,b,c){b=void 0!==b?b:42;var d=jb(a);a=ib(a);c=Ha(void 0!==c?c:256);c=Math.max(a/c[0],d/c[1]);b+=1;d=Array(b);for(a=0;a<b;++a)d[a]=c/Math.pow(2,a);return d}
function uc(a){a=Tb(a);var b=a.D();b||(a=180*xb.degrees/a.uc(),b=Wa(-a,-a,a,a));return b};function xc(a){this.b=a.html;this.a=a.tileRanges?a.tileRanges:null}xc.prototype.g=function(){return this.b};function yc(a){return function(b){if(b)return[xa(b[0],a[0],a[2]),xa(b[1],a[1],a[3])]}}function zc(a){return a};function Ac(a){function b(b){var c=a.listener,e=a.dh||a.target;a.fh&&Bc(a);return c.call(e,b)}return a.eh=b}function Cc(a,b,c,d){for(var e,f=0,g=a.length;f<g;++f)if(e=a[f],e.listener===b&&e.dh===c)return d&&(e.deleteIndex=f),e}function Dc(a,b){var c=a.mb;return c?c[b]:void 0}function Ec(a){var b=a.mb;b||(b=a.mb={});return b}
function Fc(a,b){var c=Dc(a,b);if(c){for(var d=0,e=c.length;d<e;++d)a.removeEventListener(b,c[d].eh),rb(c[d]);c.length=0;if(c=a.mb)delete c[b],Object.keys(c).length||delete a.mb}}function z(a,b,c,d,e){var f=Ec(a),g=f[b];g||(g=f[b]=[]);(f=Cc(g,c,d,!1))?e||(f.fh=!1):(f={dh:d,fh:!!e,listener:c,target:a,type:b},a.addEventListener(b,Ac(f)),g.push(f));return f}function Gc(a,b,c,d){return z(a,b,c,d,!0)}function Hc(a,b,c,d){(a=Dc(a,b))&&(c=Cc(a,c,d,!0))&&Bc(c)}
function Bc(a){if(a&&a.target){a.target.removeEventListener(a.type,a.eh);var b=Dc(a.target,a.type);if(b){var c="deleteIndex"in a?a.deleteIndex:b.indexOf(a);-1!==c&&b.splice(c,1);b.length||Fc(a.target,a.type)}rb(a)}}function Ic(a){var b=Ec(a),c;for(c in b)Fc(a,c)};function Jc(){}Jc.prototype.$b=!1;function Kc(a){a.$b||(a.$b=!0,a.ra())}Jc.prototype.ra=oa;function Lc(a){this.type=a;this.target=null}Lc.prototype.preventDefault=Lc.prototype.stopPropagation=function(){this.gp=!0};function Mc(a){a.stopPropagation()};function Nc(){this.$a={};this.ta={};this.qa={}}u(Nc,Jc);Nc.prototype.addEventListener=function(a,b){var c=this.qa[a];c||(c=this.qa[a]=[]);-1===c.indexOf(b)&&c.push(b)};
Nc.prototype.b=function(a){var b="string"===typeof a?new Lc(a):a;a=b.type;b.target=this;var c=this.qa[a],d;if(c){a in this.ta||(this.ta[a]=0,this.$a[a]=0);++this.ta[a];for(var e=0,f=c.length;e<f;++e)if(!1===c[e].call(this,b)||b.gp){d=!1;break}--this.ta[a];if(!this.ta[a]){b=this.$a[a];for(delete this.$a[a];b--;)this.removeEventListener(a,oa);delete this.ta[a]}return d}};Nc.prototype.ra=function(){Ic(this)};function Oc(a,b){return b?b in a.qa:0<Object.keys(a.qa).length}
Nc.prototype.removeEventListener=function(a,b){var c=this.qa[a];if(c){var d=c.indexOf(b);a in this.$a?(c[d]=oa,++this.$a[a]):(c.splice(d,1),c.length||delete this.qa[a])}};function Pc(){Nc.call(this);this.g=0}u(Pc,Nc);k=Pc.prototype;k.s=function(){++this.g;this.b("change")};k.L=function(){return this.g};k.J=function(a,b,c){if(Array.isArray(a)){for(var d=a.length,e=Array(d),f=0;f<d;++f)e[f]=z(this,a[f],b,c);return e}return z(this,a,b,c)};k.once=function(a,b,c){if(Array.isArray(a)){for(var d=a.length,e=Array(d),f=0;f<d;++f)e[f]=Gc(this,a[f],b,c);return e}return Gc(this,a,b,c)};
k.K=function(a,b,c){if(Array.isArray(a))for(var d=0,e=a.length;d<e;++d)Hc(this,a[d],b,c);else Hc(this,a,b,c)};function Qc(a){Pc.call(this);w(this);this.O={};void 0!==a&&this.H(a)}u(Qc,Pc);var Rc={};function Sc(a){return Rc.hasOwnProperty(a)?Rc[a]:Rc[a]="change:"+a}k=Qc.prototype;k.get=function(a){var b;this.O.hasOwnProperty(a)&&(b=this.O[a]);return b};k.P=function(){return Object.keys(this.O)};k.M=function(){return qb({},this.O)};function Tc(a,b,c){var d;d=Sc(b);a.b(new Uc(d,b,c));a.b(new Uc("propertychange",b,c))}k.set=function(a,b,c){c?this.O[a]=b:(c=this.O[a],this.O[a]=b,c!==b&&Tc(this,a,c))};
k.H=function(a,b){for(var c in a)this.set(c,a[c],b)};k.R=function(a,b){if(a in this.O){var c=this.O[a];delete this.O[a];b||Tc(this,a,c)}};function Uc(a,b,c){Lc.call(this,a);this.key=b;this.oldValue=c}u(Uc,Lc);function D(a,b){Qc.call(this);this.c=!!(b||{}).unique;this.a=a?a:[];if(this.c)for(var c=0,d=this.a.length;c<d;++c)Vc(this,this.a[c],c);Wc(this)}u(D,Qc);k=D.prototype;k.clear=function(){for(;0<this.fc();)this.pop()};k.ag=function(a){var b,c;b=0;for(c=a.length;b<c;++b)this.push(a[b]);return this};k.forEach=function(a,b){this.a.forEach(a,b)};k.pm=function(){return this.a};k.item=function(a){return this.a[a]};k.fc=function(){return this.get(Xc)};
k.Ge=function(a,b){this.c&&Vc(this,b);this.a.splice(a,0,b);Wc(this);this.b(new Yc("add",b))};k.pop=function(){return this.Bg(this.fc()-1)};k.push=function(a){this.c&&Vc(this,a);var b=this.fc();this.Ge(b,a);return this.fc()};k.remove=function(a){var b=this.a,c,d;c=0;for(d=b.length;c<d;++c)if(b[c]===a)return this.Bg(c)};k.Bg=function(a){var b=this.a[a];this.a.splice(a,1);Wc(this);this.b(new Yc("remove",b));return b};
k.Mp=function(a,b){var c=this.fc();if(a<c)this.c&&Vc(this,b,a),c=this.a[a],this.a[a]=b,this.b(new Yc("remove",c)),this.b(new Yc("add",b));else{for(;c<a;++c)this.Ge(c,void 0);this.Ge(a,b)}};function Wc(a){a.set(Xc,a.a.length)}function Vc(a,b,c){for(var d=0,e=a.a.length;d<e;++d)if(a.a[d]===b&&d!==c)throw new qa(58);}var Xc="length";function Yc(a,b){Lc.call(this,a);this.element=b}u(Yc,Lc);var Zc=/^#(?:[0-9a-f]{3}){1,2}$/i,ad=/^([a-z]*)$/i;function bd(a){return Array.isArray(a)?a:cd(a)}function dd(a){if("string"!==typeof a){var b=a[0];b!=(b|0)&&(b=b+.5|0);var c=a[1];c!=(c|0)&&(c=c+.5|0);var d=a[2];d!=(d|0)&&(d=d+.5|0);a="rgba("+b+","+c+","+d+","+(void 0===a[3]?1:a[3])+")"}return a}
var cd=function(){var a={},b=0;return function(c){var d;if(a.hasOwnProperty(c))d=a[c];else{if(1024<=b){d=0;for(var e in a)d++&3||(delete a[e],--b)}d=c;var f;ad.exec(d)&&(e=document.createElement("div"),e.style.color=d,document.body.appendChild(e),d=getComputedStyle(e).color,document.body.removeChild(e));if(Zc.exec(d)){f=d.length-1;sa(3==f||6==f,54);var g=3==f?1:2;f=parseInt(d.substr(1+0*g,g),16);e=parseInt(d.substr(1+1*g,g),16);d=parseInt(d.substr(1+2*g,g),16);1==g&&(f=(f<<4)+f,e=(e<<4)+e,d=(d<<4)+
d);f=[f,e,d,1]}else d.indexOf("rgba(")?d.indexOf("rgb(")?sa(!1,14):(d=d.slice(4,-1).split(",").map(Number),d.push(1),f=ed(d)):(d=d.slice(5,-1).split(",").map(Number),f=ed(d));d=f;a[c]=d;++b}return d}}();function ed(a){var b=[];b[0]=xa(a[0]+.5|0,0,255);b[1]=xa(a[1]+.5|0,0,255);b[2]=xa(a[2]+.5|0,0,255);b[3]=xa(a[3],0,1);return b};function fd(a){return"string"===typeof a||a instanceof CanvasPattern||a instanceof CanvasGradient?a:dd(a)};function gd(a,b,c){this.center=a;this.resolution=b;this.rotation=c};function hd(a,b){var c=document.createElement("CANVAS");a&&(c.width=a);b&&(c.height=b);return c.getContext("2d")}function id(a,b){var c=b.parentNode;c&&c.replaceChild(a,b)}function jd(a){a&&a.parentNode&&a.parentNode.removeChild(a)};function kd(a){Qc.call(this);this.element=a.element?a.element:null;this.a=this.Z=null;this.u=[];this.render=a.render?a.render:oa;a.target&&this.i(a.target)}u(kd,Qc);kd.prototype.ra=function(){jd(this.element);Qc.prototype.ra.call(this)};kd.prototype.f=function(){return this.a};
kd.prototype.setMap=function(a){this.a&&jd(this.element);for(var b=0,c=this.u.length;b<c;++b)Bc(this.u[b]);this.u.length=0;if(this.a=a)(this.Z?this.Z:a.v).appendChild(this.element),this.render!==oa&&this.u.push(z(a,"postrender",this.render,this)),a.render()};kd.prototype.i=function(a){this.Z="string"===typeof a?document.getElementById(a):a};function ld(a){a=a?a:{};this.I=document.createElement("UL");this.v=document.createElement("LI");this.I.appendChild(this.v);this.v.style.display="none";this.c=void 0!==a.collapsed?a.collapsed:!0;this.l=void 0!==a.collapsible?a.collapsible:!0;this.l||(this.c=!1);var b=void 0!==a.className?a.className:"ol-attribution",c=void 0!==a.tipLabel?a.tipLabel:"Attributions",d=void 0!==a.collapseLabel?a.collapseLabel:"\u00bb";"string"===typeof d?(this.A=document.createElement("span"),this.A.textContent=d):this.A=
d;d=void 0!==a.label?a.label:"i";"string"===typeof d?(this.C=document.createElement("span"),this.C.textContent=d):this.C=d;var e=this.l&&!this.c?this.A:this.C,d=document.createElement("button");d.setAttribute("type","button");d.title=c;d.appendChild(e);z(d,"click",this.Pm,this);c=document.createElement("div");c.className=b+" ol-unselectable ol-control"+(this.c&&this.l?" ol-collapsed":"")+(this.l?"":" ol-uncollapsible");c.appendChild(this.I);c.appendChild(d);kd.call(this,{element:c,render:a.render?
a.render:md,target:a.target});this.G=!0;this.o={};this.j={};this.T={}}u(ld,kd);
function md(a){if(a=a.frameState){var b,c,d,e,f,g,h,l,m,n,p,q=a.layerStatesArray,r=qb({},a.attributions),v={},x={},y=a.viewState.projection;c=0;for(b=q.length;c<b;c++)if(g=q[c].layer.ka())if(n=w(g).toString(),m=g.j)for(d=0,e=m.length;d<e;d++)if(h=m[d],l=w(h).toString(),!(l in r)){if(f=a.usedTiles[n]){var A=g.Jb(y);a:{p=void 0;var B,aa,Ra=h,ra=A,Ka=y;if(Ra.a){for(p in f)if(p in Ra.a){var A=f[p],C;aa=0;for(B=Ra.a[p].length;aa<B;++aa){C=Ra.a[p][aa];if(wa(C,A)){p=!0;break a}var Na=nc(ra,uc(Ka),parseInt(p,
10)),wb=Na.ba-Na.da+1;if(A.da<Na.da||A.ba>Na.ba)if(wa(C,new ta(Da(A.da,wb),Da(A.ba,wb),A.ga,A.ja))||A.ba-A.da+1>wb&&wa(C,Na)){p=!0;break a}}}p=!1}else p=!0}}else p=!1;p?(l in v&&delete v[l],p=h.b,p in x||(x[p]=!0,r[l]=h)):v[l]=h}b=[r,v];c=b[0];b=b[1];for(var Z in this.o)Z in c?(this.j[Z]||(this.o[Z].style.display="",this.j[Z]=!0),delete c[Z]):Z in b?(this.j[Z]&&(this.o[Z].style.display="none",delete this.j[Z]),delete b[Z]):(jd(this.o[Z]),delete this.o[Z],delete this.j[Z]);for(Z in c)d=document.createElement("LI"),
d.innerHTML=c[Z].b,this.I.appendChild(d),this.o[Z]=d,this.j[Z]=!0;for(Z in b)d=document.createElement("LI"),d.innerHTML=b[Z].b,d.style.display="none",this.I.appendChild(d),this.o[Z]=d;Z=!tb(this.j)||!tb(a.logos);this.G!=Z&&(this.element.style.display=Z?"":"none",this.G=Z);Z&&tb(this.j)?this.element.classList.add("ol-logo-only"):this.element.classList.remove("ol-logo-only");var Ta;a=a.logos;Z=this.T;for(Ta in Z)Ta in a||(jd(Z[Ta]),delete Z[Ta]);for(var Pb in a)b=a[Pb],b instanceof HTMLElement&&(this.v.appendChild(b),
Z[Pb]=b),Pb in Z||(Ta=new Image,Ta.src=Pb,""===b?c=Ta:(c=document.createElement("a"),c.href=b,c.appendChild(Ta)),this.v.appendChild(c),Z[Pb]=c);this.v.style.display=tb(a)?"none":""}else this.G&&(this.element.style.display="none",this.G=!1)}k=ld.prototype;k.Pm=function(a){a.preventDefault();nd(this)};function nd(a){a.element.classList.toggle("ol-collapsed");a.c?id(a.A,a.C):id(a.C,a.A);a.c=!a.c}k.Om=function(){return this.l};
k.Rm=function(a){this.l!==a&&(this.l=a,this.element.classList.toggle("ol-uncollapsible"),!a&&this.c&&nd(this))};k.Qm=function(a){this.l&&this.c!==a&&nd(this)};k.Nm=function(){return this.c};function od(a){return Math.pow(a,3)}function pd(a){return 1-od(1-a)}function qd(a){return 3*a*a-2*a*a*a}function rd(a){return a};function sd(a){a=a?a:{};var b=void 0!==a.className?a.className:"ol-rotate",c=void 0!==a.label?a.label:"\u21e7";this.c=null;"string"===typeof c?(this.c=document.createElement("span"),this.c.className="ol-compass",this.c.textContent=c):(this.c=c,this.c.classList.add("ol-compass"));var d=a.tipLabel?a.tipLabel:"Reset rotation",c=document.createElement("button");c.className=b+"-reset";c.setAttribute("type","button");c.title=d;c.appendChild(this.c);z(c,"click",sd.prototype.A,this);d=document.createElement("div");
d.className=b+" ol-unselectable ol-control";d.appendChild(c);b=a.render?a.render:td;this.l=a.resetNorth?a.resetNorth:void 0;kd.call(this,{element:d,render:b,target:a.target});this.o=void 0!==a.duration?a.duration:250;this.j=void 0!==a.autoHide?a.autoHide:!0;this.v=void 0;this.j&&this.element.classList.add("ol-hidden")}u(sd,kd);sd.prototype.A=function(a){a.preventDefault();this.l?this.l():(a=this.a.$())&&void 0!==a.Sa()&&(0<this.o?a.animate({rotation:0,duration:this.o,easing:pd}):a.Ne(0))};
function td(a){if(a=a.frameState){a=a.viewState.rotation;if(a!=this.v){var b="rotate("+a+"rad)";if(this.j){var c=this.element.classList.contains("ol-hidden");c||a?c&&a&&this.element.classList.remove("ol-hidden"):this.element.classList.add("ol-hidden")}this.c.style.msTransform=b;this.c.style.webkitTransform=b;this.c.style.transform=b}this.v=a}};function ud(a){a=a?a:{};var b=void 0!==a.className?a.className:"ol-zoom",c=void 0!==a.delta?a.delta:1,d=void 0!==a.zoomInLabel?a.zoomInLabel:"+",e=void 0!==a.zoomOutLabel?a.zoomOutLabel:"\u2212",f=void 0!==a.zoomInTipLabel?a.zoomInTipLabel:"Zoom in",g=void 0!==a.zoomOutTipLabel?a.zoomOutTipLabel:"Zoom out",h=document.createElement("button");h.className=b+"-in";h.setAttribute("type","button");h.title=f;h.appendChild("string"===typeof d?document.createTextNode(d):d);z(h,"click",ud.prototype.j.bind(this,
c));d=document.createElement("button");d.className=b+"-out";d.setAttribute("type","button");d.title=g;d.appendChild("string"===typeof e?document.createTextNode(e):e);z(d,"click",ud.prototype.j.bind(this,-c));c=document.createElement("div");c.className=b+" ol-unselectable ol-control";c.appendChild(h);c.appendChild(d);kd.call(this,{element:c,target:a.target});this.c=void 0!==a.duration?a.duration:250}u(ud,kd);
ud.prototype.j=function(a,b){b.preventDefault();var c=this.a.$();if(c){var d=c.Ra();d&&(d=c.constrainResolution(d,a),0<this.c?(c.Kc()&&c.kd(),c.animate({resolution:d,duration:this.c,easing:pd})):c.$c(d))}};function vd(a){a=a?a:{};var b=new D;(void 0!==a.zoom?a.zoom:1)&&b.push(new ud(a.zoomOptions));(void 0!==a.rotate?a.rotate:1)&&b.push(new sd(a.rotateOptions));(void 0!==a.attribution?a.attribution:1)&&b.push(new ld(a.attributionOptions));return b};function wd(a){a=a?a:{};this.c=void 0!==a.className?a.className:"ol-full-screen";var b=void 0!==a.label?a.label:"\u2922";this.l="string"===typeof b?document.createTextNode(b):b;b=void 0!==a.labelActive?a.labelActive:"\u00d7";this.o="string"===typeof b?document.createTextNode(b):b;var c=a.tipLabel?a.tipLabel:"Toggle full-screen",b=document.createElement("button");b.className=this.c+"-"+xd();b.setAttribute("type","button");b.title=c;b.appendChild(this.l);z(b,"click",this.C,this);c=document.createElement("div");
c.className=this.c+" ol-unselectable ol-control "+(yd()?"":"ol-unsupported");c.appendChild(b);kd.call(this,{element:c,target:a.target});this.A=void 0!==a.keys?a.keys:!1;this.j=a.source}u(wd,kd);
wd.prototype.C=function(a){a.preventDefault();yd()&&(a=this.a)&&(xd()?document.exitFullscreen?document.exitFullscreen():document.msExitFullscreen?document.msExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitExitFullscreen&&document.webkitExitFullscreen():(a=this.j?"string"===typeof this.j?document.getElementById(this.j):this.j:a.vc(),this.A?a.mozRequestFullScreenWithKeys?a.mozRequestFullScreenWithKeys():a.webkitRequestFullscreen?a.webkitRequestFullscreen(Element.ALLOW_KEYBOARD_INPUT):
zd(a):zd(a)))};wd.prototype.v=function(){var a=this.element.firstElementChild,b=this.a;xd()?(a.className=this.c+"-true",id(this.o,this.l)):(a.className=this.c+"-false",id(this.l,this.o));b&&b.Cd()};wd.prototype.setMap=function(a){kd.prototype.setMap.call(this,a);a&&this.u.push(z(document,Ad(),this.v,this))};
function yd(){var a=document.body;return!!(a.webkitRequestFullscreen||a.mozRequestFullScreen&&document.mozFullScreenEnabled||a.msRequestFullscreen&&document.msFullscreenEnabled||a.requestFullscreen&&document.fullscreenEnabled)}function xd(){return!!(document.webkitIsFullScreen||document.mozFullScreen||document.msFullscreenElement||document.fullscreenElement)}
function zd(a){a.requestFullscreen?a.requestFullscreen():a.msRequestFullscreen?a.msRequestFullscreen():a.mozRequestFullScreen?a.mozRequestFullScreen():a.webkitRequestFullscreen&&a.webkitRequestFullscreen()}var Ad=function(){var a;return function(){if(!a){var b=document.body;b.webkitRequestFullscreen?a="webkitfullscreenchange":b.mozRequestFullScreen?a="mozfullscreenchange":b.msRequestFullscreen?a="MSFullscreenChange":b.requestFullscreen&&(a="fullscreenchange")}return a}}();function Bd(a){a=a?a:{};var b=document.createElement("DIV");b.className=void 0!==a.className?a.className:"ol-mouse-position";kd.call(this,{element:b,render:a.render?a.render:Cd,target:a.target});z(this,Sc(Dd),this.Sm,this);a.coordinateFormat&&this.fj(a.coordinateFormat);a.projection&&this.Th(Tb(a.projection));this.v=void 0!==a.undefinedHTML?a.undefinedHTML:"";this.o=b.innerHTML;this.l=this.j=this.c=null}u(Bd,kd);
function Cd(a){a=a.frameState;a?this.c!=a.viewState.projection&&(this.c=a.viewState.projection,this.j=null):this.c=null;Ed(this,this.l)}k=Bd.prototype;k.Sm=function(){this.j=null};k.qh=function(){return this.get(Fd)};k.Sh=function(){return this.get(Dd)};k.Gl=function(a){this.l=this.a.xe(a);Ed(this,this.l)};k.Hl=function(){Ed(this,null);this.l=null};k.setMap=function(a){kd.prototype.setMap.call(this,a);a&&(a=a.c,this.u.push(z(a,"mousemove",this.Gl,this),z(a,"mouseout",this.Hl,this)))};
k.fj=function(a){this.set(Fd,a)};k.Th=function(a){this.set(Dd,a)};function Ed(a,b){var c=a.v;if(b&&a.c){if(!a.j){var d=a.Sh();a.j=d?Sb(a.c,d):ec}if(d=a.a.Xa(b))a.j(d,d),c=(c=a.qh())?c(d):d.toString()}a.o&&c==a.o||(a.element.innerHTML=c,a.o=c)}var Dd="projection",Fd="coordinateFormat";function Gd(a,b,c){Lc.call(this,a);this.map=b;this.frameState=void 0!==c?c:null}u(Gd,Lc);function Hd(a,b,c,d,e){Gd.call(this,a,b,e);this.originalEvent=c;this.pixel=b.xe(c);this.coordinate=b.Xa(this.pixel);this.dragging=void 0!==d?d:!1}u(Hd,Gd);Hd.prototype.preventDefault=function(){Gd.prototype.preventDefault.call(this);this.originalEvent.preventDefault()};Hd.prototype.stopPropagation=function(){Gd.prototype.stopPropagation.call(this);this.originalEvent.stopPropagation()};var Id={xq:"singleclick",mq:"click",nq:"dblclick",qq:"pointerdrag",tq:"pointermove",pq:"pointerdown",wq:"pointerup",vq:"pointerover",uq:"pointerout",rq:"pointerenter",sq:"pointerleave",oq:"pointercancel"};function Kd(a,b,c,d,e){Hd.call(this,a,b,c.b,d,e);this.b=c}u(Kd,Hd);var Ld=["experimental-webgl","webgl","webkit-3d","moz-webgl"];function Md(a,b){var c,d,e=Ld.length;for(d=0;d<e;++d)try{if(c=a.getContext(Ld[d],b))return c}catch(f){}return null};var Nd,Od="undefined"!==typeof navigator?navigator.userAgent.toLowerCase():"",Pd=-1!==Od.indexOf("firefox"),Qd=-1!==Od.indexOf("safari")&&-1==Od.indexOf("chrom"),Rd=-1!==Od.indexOf("webkit")&&-1==Od.indexOf("edge"),Sd=-1!==Od.indexOf("macintosh"),Td=window.devicePixelRatio||1,Ud=!1,Vd=function(){if(!("HTMLCanvasElement"in window))return!1;try{var a=document.createElement("CANVAS").getContext("2d");return a?(void 0!==a.setLineDash&&(Ud=!0),!0):!1}catch(b){return!1}}(),Wd="DeviceOrientationEvent"in
window,Xd="geolocation"in navigator,Yd="ontouchstart"in window,Zd="PointerEvent"in window,$d=!!navigator.msPointerEnabled,ae=!1,be,ce=[];if("WebGLRenderingContext"in window)try{var de=Md(document.createElement("CANVAS"),{failIfMajorPerformanceCaveat:!0});de&&(ae=!0,be=de.getParameter(de.MAX_TEXTURE_SIZE),ce=de.getSupportedExtensions())}catch(a){}Nd=ae;da=ce;ca=be;function ee(a,b){this.b=a;this.i=b};function fe(a){ee.call(this,a,{mousedown:this.am,mousemove:this.bm,mouseup:this.em,mouseover:this.dm,mouseout:this.cm});this.a=a.g;this.g=[]}u(fe,ee);function ge(a,b){for(var c=a.g,d=b.clientX,e=b.clientY,f=0,g=c.length,h;f<g&&(h=c[f]);f++){var l=Math.abs(e-h[1]);if(25>=Math.abs(d-h[0])&&25>=l)return!0}return!1}function he(a){var b=ie(a,a),c=b.preventDefault;b.preventDefault=function(){a.preventDefault();c()};b.pointerId=1;b.isPrimary=!0;b.pointerType="mouse";return b}k=fe.prototype;
k.am=function(a){if(!ge(this,a)){(1).toString()in this.a&&this.cancel(a);var b=he(a);this.a[(1).toString()]=a;je(this.b,"pointerdown",b,a)}};k.bm=function(a){if(!ge(this,a)){var b=he(a);je(this.b,"pointermove",b,a)}};k.em=function(a){if(!ge(this,a)){var b=this.a[(1).toString()];b&&b.button===a.button&&(b=he(a),je(this.b,"pointerup",b,a),delete this.a[(1).toString()])}};k.dm=function(a){if(!ge(this,a)){var b=he(a);ke(this.b,b,a)}};k.cm=function(a){if(!ge(this,a)){var b=he(a);le(this.b,b,a)}};
k.cancel=function(a){var b=he(a);this.b.cancel(b,a);delete this.a[(1).toString()]};function me(a){ee.call(this,a,{MSPointerDown:this.jm,MSPointerMove:this.km,MSPointerUp:this.nm,MSPointerOut:this.lm,MSPointerOver:this.mm,MSPointerCancel:this.im,MSGotPointerCapture:this.gm,MSLostPointerCapture:this.hm});this.a=a.g;this.g=["","unavailable","touch","pen","mouse"]}u(me,ee);function ne(a,b){var c=b;"number"===typeof b.pointerType&&(c=ie(b,b),c.pointerType=a.g[b.pointerType]);return c}k=me.prototype;
k.jm=function(a){this.a[a.pointerId.toString()]=a;var b=ne(this,a);je(this.b,"pointerdown",b,a)};k.km=function(a){var b=ne(this,a);je(this.b,"pointermove",b,a)};k.nm=function(a){var b=ne(this,a);je(this.b,"pointerup",b,a);delete this.a[a.pointerId.toString()]};k.lm=function(a){var b=ne(this,a);le(this.b,b,a)};k.mm=function(a){var b=ne(this,a);ke(this.b,b,a)};k.im=function(a){var b=ne(this,a);this.b.cancel(b,a);delete this.a[a.pointerId.toString()]};
k.hm=function(a){this.b.b(new oe("lostpointercapture",a,a))};k.gm=function(a){this.b.b(new oe("gotpointercapture",a,a))};function pe(a){ee.call(this,a,{pointerdown:this.Yo,pointermove:this.Zo,pointerup:this.bp,pointerout:this.$o,pointerover:this.ap,pointercancel:this.Xo,gotpointercapture:this.pl,lostpointercapture:this.$l})}u(pe,ee);k=pe.prototype;k.Yo=function(a){qe(this.b,a)};k.Zo=function(a){qe(this.b,a)};k.bp=function(a){qe(this.b,a)};k.$o=function(a){qe(this.b,a)};k.ap=function(a){qe(this.b,a)};k.Xo=function(a){qe(this.b,a)};k.$l=function(a){qe(this.b,a)};k.pl=function(a){qe(this.b,a)};function oe(a,b,c){Lc.call(this,a);this.b=b;a=c?c:{};this.buttons=se(a);this.pressure=te(a,this.buttons);this.bubbles="bubbles"in a?a.bubbles:!1;this.cancelable="cancelable"in a?a.cancelable:!1;this.view="view"in a?a.view:null;this.detail="detail"in a?a.detail:null;this.screenX="screenX"in a?a.screenX:0;this.screenY="screenY"in a?a.screenY:0;this.clientX="clientX"in a?a.clientX:0;this.clientY="clientY"in a?a.clientY:0;this.button="button"in a?a.button:0;this.relatedTarget="relatedTarget"in a?a.relatedTarget:
null;this.pointerId="pointerId"in a?a.pointerId:0;this.width="width"in a?a.width:0;this.height="height"in a?a.height:0;this.pointerType="pointerType"in a?a.pointerType:"";this.isPrimary="isPrimary"in a?a.isPrimary:!1;b.preventDefault&&(this.preventDefault=function(){b.preventDefault()})}u(oe,Lc);function se(a){if(a.buttons||ue)a=a.buttons;else switch(a.which){case 1:a=1;break;case 2:a=4;break;case 3:a=2;break;default:a=0}return a}
function te(a,b){var c=0;a.pressure?c=a.pressure:c=b?.5:0;return c}var ue=!1;try{ue=1===(new MouseEvent("click",{buttons:1})).buttons}catch(a){};function ve(a,b){ee.call(this,a,{touchstart:this.gq,touchmove:this.fq,touchend:this.eq,touchcancel:this.cq});this.a=a.g;this.j=b;this.g=void 0;this.f=0;this.c=void 0}u(ve,ee);k=ve.prototype;k.dj=function(){this.f=0;this.c=void 0};
function we(a,b,c){b=ie(b,c);b.pointerId=c.identifier+2;b.bubbles=!0;b.cancelable=!0;b.detail=a.f;b.button=0;b.buttons=1;b.width=c.webkitRadiusX||c.radiusX||0;b.height=c.webkitRadiusY||c.radiusY||0;b.pressure=c.webkitForce||c.force||.5;b.isPrimary=a.g===c.identifier;b.pointerType="touch";b.clientX=c.clientX;b.clientY=c.clientY;b.screenX=c.screenX;b.screenY=c.screenY;return b}
function xe(a,b,c){function d(){b.preventDefault()}var e=Array.prototype.slice.call(b.changedTouches),f=e.length,g,h;for(g=0;g<f;++g)h=we(a,b,e[g]),h.preventDefault=d,c.call(a,b,h)}
k.gq=function(a){var b=a.touches,c=Object.keys(this.a),d=c.length;if(d>=b.length){var e=[],f,g,h;for(f=0;f<d;++f){g=c[f];h=this.a[g];var l;if(!(l=1==g))a:{for(var m=b.length,n=0;n<m;n++)if(l=b[n],l.identifier===g-2){l=!0;break a}l=!1}l||e.push(h.out)}for(f=0;f<e.length;++f)this.Gf(a,e[f])}b=a.changedTouches[0];c=Object.keys(this.a).length;if(!c||1===c&&(1).toString()in this.a)this.g=b.identifier,void 0!==this.c&&clearTimeout(this.c);ye(this,a);this.f++;xe(this,a,this.To)};
k.To=function(a,b){this.a[b.pointerId]={target:b.target,out:b,Qi:b.target};var c=this.b;b.bubbles=!0;je(c,"pointerover",b,a);c=this.b;b.bubbles=!1;je(c,"pointerenter",b,a);je(this.b,"pointerdown",b,a)};k.fq=function(a){a.preventDefault();xe(this,a,this.fm)};
k.fm=function(a,b){var c=this.a[b.pointerId];if(c){var d=c.out,e=c.Qi;je(this.b,"pointermove",b,a);d&&e!==b.target&&(d.relatedTarget=b.target,b.relatedTarget=e,d.target=e,b.target?(le(this.b,d,a),ke(this.b,b,a)):(b.target=e,b.relatedTarget=null,this.Gf(a,b)));c.out=b;c.Qi=b.target}};k.eq=function(a){ye(this,a);xe(this,a,this.hq)};
k.hq=function(a,b){je(this.b,"pointerup",b,a);this.b.out(b,a);ze(this.b,b,a);delete this.a[b.pointerId];b.isPrimary&&(this.g=void 0,this.c=setTimeout(this.dj.bind(this),200))};k.cq=function(a){xe(this,a,this.Gf)};k.Gf=function(a,b){this.b.cancel(b,a);this.b.out(b,a);ze(this.b,b,a);delete this.a[b.pointerId];b.isPrimary&&(this.g=void 0,this.c=setTimeout(this.dj.bind(this),200))};
function ye(a,b){var c=a.j.g,d=b.changedTouches[0];if(a.g===d.identifier){var e=[d.clientX,d.clientY];c.push(e);setTimeout(function(){var a=c.indexOf(e);-1<a&&c.splice(a,1)},2500)}};function Ae(a){Nc.call(this);this.f=a;this.g={};this.i={};this.a=[];Zd?Be(this,new pe(this)):$d?Be(this,new me(this)):(a=new fe(this),Be(this,a),Yd&&Be(this,new ve(this,a)));a=this.a.length;for(var b,c=0;c<a;c++)b=this.a[c],Ce(this,Object.keys(b.i))}u(Ae,Nc);function Be(a,b){var c=Object.keys(b.i);c&&(c.forEach(function(a){var c=b.i[a];c&&(this.i[a]=c.bind(b))},a),a.a.push(b))}Ae.prototype.c=function(a){var b=this.i[a.type];b&&b(a)};
function Ce(a,b){b.forEach(function(a){z(this.f,a,this.c,this)},a)}function De(a,b){b.forEach(function(a){Hc(this.f,a,this.c,this)},a)}function ie(a,b){for(var c={},d,e=0,f=Ee.length;e<f;e++)d=Ee[e][0],c[d]=a[d]||b[d]||Ee[e][1];return c}function ze(a,b,c){b.bubbles=!1;je(a,"pointerleave",b,c)}Ae.prototype.out=function(a,b){a.bubbles=!0;je(this,"pointerout",a,b)};Ae.prototype.cancel=function(a,b){je(this,"pointercancel",a,b)};
function le(a,b,c){a.out(b,c);var d=b.target,e=b.relatedTarget;d&&e&&d.contains(e)||ze(a,b,c)}function ke(a,b,c){b.bubbles=!0;je(a,"pointerover",b,c);var d=b.target,e=b.relatedTarget;d&&e&&d.contains(e)||(b.bubbles=!1,je(a,"pointerenter",b,c))}function je(a,b,c,d){a.b(new oe(b,d,c))}function qe(a,b){a.b(new oe(b.type,b,b))}Ae.prototype.ra=function(){for(var a=this.a.length,b,c=0;c<a;c++)b=this.a[c],De(this,Object.keys(b.i));Nc.prototype.ra.call(this)};
var Ee=[["bubbles",!1],["cancelable",!1],["view",null],["detail",null],["screenX",0],["screenY",0],["clientX",0],["clientY",0],["ctrlKey",!1],["altKey",!1],["shiftKey",!1],["metaKey",!1],["button",0],["relatedTarget",null],["buttons",0],["pointerId",0],["width",0],["height",0],["pressure",0],["tiltX",0],["tiltY",0],["pointerType",""],["hwTimestamp",0],["isPrimary",!1],["type",""],["target",null],["currentTarget",null],["which",0]];function Fe(a){Nc.call(this);this.c=a;this.j=0;this.l=!1;this.i=[];this.g=null;a=this.c.c;this.O=0;this.v={};this.f=new Ae(a);this.a=null;this.o=z(this.f,"pointerdown",this.Jl,this);this.u=z(this.f,"pointermove",this.Bp,this)}u(Fe,Nc);function Ge(a,b){var c=new Kd("click",a.c,b);a.b(c);a.j?(clearTimeout(a.j),a.j=0,c=new Kd("dblclick",a.c,b),a.b(c)):a.j=setTimeout(function(){this.j=0;var a=new Kd("singleclick",this.c,b);this.b(a)}.bind(a),250)}
function He(a,b){"pointerup"==b.type||"pointercancel"==b.type?delete a.v[b.pointerId]:"pointerdown"==b.type&&(a.v[b.pointerId]=!0);a.O=Object.keys(a.v).length}k=Fe.prototype;k.Ch=function(a){He(this,a);var b=new Kd("pointerup",this.c,a);this.b(b);this.l||a.button||Ge(this,this.g);this.O||(this.i.forEach(Bc),this.i.length=0,this.l=!1,this.g=null,Kc(this.a),this.a=null)};
k.Jl=function(a){He(this,a);var b=new Kd("pointerdown",this.c,a);this.b(b);this.g=a;this.i.length||(this.a=new Ae(document),this.i.push(z(this.a,"pointermove",this.Dm,this),z(this.a,"pointerup",this.Ch,this),z(this.f,"pointercancel",this.Ch,this)))};k.Dm=function(a){if(a.clientX!=this.g.clientX||a.clientY!=this.g.clientY){this.l=!0;var b=new Kd("pointerdrag",this.c,a,this.l);this.b(b)}a.preventDefault()};
k.Bp=function(a){this.b(new Kd(a.type,this.c,a,!(!this.g||a.clientX==this.g.clientX&&a.clientY==this.g.clientY)))};k.ra=function(){this.u&&(Bc(this.u),this.u=null);this.o&&(Bc(this.o),this.o=null);this.i.forEach(Bc);this.i.length=0;this.a&&(Kc(this.a),this.a=null);this.f&&(Kc(this.f),this.f=null);Nc.prototype.ra.call(this)};function Ie(a,b){this.o=a;this.c=b;this.b=[];this.g=[];this.a={}}Ie.prototype.clear=function(){this.b.length=0;this.g.length=0;rb(this.a)};function Je(a){var b=a.b,c=a.g,d=b[0];1==b.length?(b.length=0,c.length=0):(b[0]=b.pop(),c[0]=c.pop(),Ke(a,0));b=a.c(d);delete a.a[b];return d}Ie.prototype.i=function(a){sa(!(this.c(a)in this.a),31);var b=this.o(a);return Infinity!=b?(this.b.push(a),this.g.push(b),this.a[this.c(a)]=!0,Le(this,0,this.b.length-1),!0):!1};
function Ke(a,b){for(var c=a.b,d=a.g,e=c.length,f=c[b],g=d[b],h=b;b<e>>1;){var l=2*b+1,m=2*b+2,l=m<e&&d[m]<d[l]?m:l;c[b]=c[l];d[b]=d[l];b=l}c[b]=f;d[b]=g;Le(a,h,b)}function Le(a,b,c){var d=a.b;a=a.g;for(var e=d[c],f=a[c];c>b;){var g=c-1>>1;if(a[g]>f)d[c]=d[g],a[c]=a[g],c=g;else break}d[c]=e;a[c]=f}function Me(a){var b=a.o,c=a.b,d=a.g,e=0,f=c.length,g,h,l;for(h=0;h<f;++h)g=c[h],l=b(g),Infinity==l?delete a.a[a.c(g)]:(d[e]=l,c[e++]=g);c.length=e;d.length=e;for(b=(a.b.length>>1)-1;0<=b;b--)Ke(a,b)};function Ne(a,b){Ie.call(this,function(b){return a.apply(null,b)},function(a){return a[0].hb()});this.u=b;this.j=0;this.f={}}u(Ne,Ie);Ne.prototype.i=function(a){var b=Ie.prototype.i.call(this,a);b&&z(a[0],"change",this.l,this);return b};Ne.prototype.l=function(a){a=a.target;var b=a.V();if(2===b||3===b||4===b||5===b)Hc(a,"change",this.l,this),a=a.hb(),a in this.f&&(delete this.f[a],--this.j),this.u()};
function Oe(a,b,c){for(var d=0,e,f;a.j<b&&d<c&&0<a.b.length;)e=Je(a)[0],f=e.hb(),0!==e.V()||f in a.f||(a.f[f]=!0,++a.j,++d,e.load())};function Pe(a){return function(b,c,d){if(void 0!==b)return b=ga(a,b,d),b=xa(b+c,0,a.length-1),c=Math.floor(b),b!=c&&c<a.length-1?a[c]/Math.pow(a[c]/a[c+1],b-c):a[c]}}function Qe(a,b,c){return function(d,e,f){if(void 0!==d)return d=Math.max(Math.floor(Math.log(b/d)/Math.log(a)+(-f/2+.5))+e,0),void 0!==c&&(d=Math.min(d,c)),b/Math.pow(a,d)}};function Re(a){if(void 0!==a)return 0}function Se(a,b){if(void 0!==a)return a+b}function Te(a){var b=2*Math.PI/a;return function(a,d){if(void 0!==a)return a=Math.floor((a+d)/b+.5)*b}}function Ue(){var a=Ca(5);return function(b,c){if(void 0!==b)return Math.abs(b+c)<=a?0:b+c}};function Ve(a,b){var c=void 0!==b?a.toFixed(b):""+a,d=c.indexOf("."),d=-1===d?c.length:d;return 2<d?c:Array(3-d).join("0")+c}function We(a){a=(""+a).split(".");for(var b=["1","3"],c=0;c<Math.max(a.length,b.length);c++){var d=parseInt(a[c]||"0",10),e=parseInt(b[c]||"0",10);if(d>e)return 1;if(e>d)return-1}return 0};function Xe(a,b){a[0]+=b[0];a[1]+=b[1];return a}function Ye(a,b){var c=a[0],d=a[1],e=b[0],f=b[1],g=e[0],e=e[1],h=f[0],f=f[1],l=h-g,m=f-e,c=l||m?(l*(c-g)+m*(d-e))/(l*l+m*m||0):0;0>=c||(1<=c?(g=h,e=f):(g+=c*l,e+=c*m));return[g,e]}
function Ze(a,b,c){a=Da(a+180,360)-180;var d=Math.abs(3600*a);c=c||0;var e=Math.pow(10,c),f=Math.floor(d/3600),g=Math.floor((d-3600*f)/60),d=Math.ceil((d-3600*f-60*g)*e)/e;60<=d&&(d=0,g+=1);60<=g&&(g=0,f+=1);return f+"\u00b0 "+Ve(g)+"\u2032 "+Ve(d,c)+"\u2033 "+b.charAt(0>a?1:0)}function $e(a,b,c){return a?b.replace("{x}",a[0].toFixed(c)).replace("{y}",a[1].toFixed(c)):""}function af(a,b){for(var c=!0,d=a.length-1;0<=d;--d)if(a[d]!=b[d]){c=!1;break}return c}
function cf(a,b){var c=Math.cos(b),d=Math.sin(b),e=a[1]*c+a[0]*d;a[0]=a[0]*c-a[1]*d;a[1]=e;return a}function df(a,b){a[0]*=b;a[1]*=b}function ef(a,b){var c=a[0]-b[0],d=a[1]-b[1];return c*c+d*d}function ff(a,b){return Math.sqrt(ef(a,b))}function gf(a,b){return ef(a,Ye(a,b))}function hf(a,b){return $e(a,"{x}, {y}",b)};function jf(){return!0}function kf(){return!1};function lf(){Qc.call(this);this.o=Ja();this.u=-1;this.i={};this.l=this.f=0}u(lf,Qc);k=lf.prototype;k.Ab=function(a,b){var c=b?b:[NaN,NaN];this.Hb(a[0],a[1],c,Infinity);return c};k.sb=function(a){return this.Sc(a[0],a[1])};k.Sc=kf;k.D=function(a){this.u!=this.g&&(this.o=this.se(this.o),this.u=this.g);var b=this.o;a?(a[0]=b[0],a[1]=b[1],a[2]=b[2],a[3]=b[3]):a=b;return a};k.Qb=function(a){return this.Td(a*a)};k.tb=function(a,b){this.Fc(dc(a,b));return this};function mf(a,b,c,d,e,f){for(var g=f?f:[],h=0;b<c;b+=d){var l=a[b],m=a[b+1];g[h++]=e[0]*l+e[2]*m+e[4];g[h++]=e[1]*l+e[3]*m+e[5]}f&&g.length!=h&&(g.length=h);return g}function nf(a,b,c,d,e,f){var g=f?f:[],h=0,l,m;for(l=0;l<b;l+=c)for(g[h++]=a[l]+d,g[h++]=a[l+1]+e,m=l+2;m<l+c;++m)g[h++]=a[m];f&&g.length!=h&&(g.length=h);return g};function of(){lf.call(this);this.la="XY";this.a=2;this.B=null}u(of,lf);function pf(a){var b;"XY"==a?b=2:"XYZ"==a||"XYM"==a?b=3:"XYZM"==a&&(b=4);return b}k=of.prototype;k.Sc=kf;k.se=function(a){return Ya(this.B,0,this.B.length,this.a,a)};k.cc=function(){return this.B.slice(0,this.a)};k.ia=function(){return this.B};k.dc=function(){return this.B.slice(this.B.length-this.a)};k.ec=function(){return this.la};
k.Td=function(a){this.l!=this.g&&(rb(this.i),this.f=0,this.l=this.g);if(0>a||this.f&&a<=this.f)return this;var b=a.toString();if(this.i.hasOwnProperty(b))return this.i[b];var c=this.od(a);if(c.ia().length<this.B.length)return this.i[b]=c;this.f=a;return this};k.od=function(){return this};k.sa=function(){return this.a};function qf(a,b,c){a.a=pf(b);a.la=b;a.B=c}
function rf(a,b,c,d){if(b)c=pf(b);else{for(b=0;b<d;++b)if(c.length)c=c[0];else{a.la="XY";a.a=2;return}c=c.length;var e;2==c?e="XY":3==c?e="XYZ":4==c&&(e="XYZM");b=e}a.la=b;a.a=c}k.Fc=function(a){this.B&&(a(this.B,this.B,this.a),this.s())};
k.rotate=function(a,b){var c=this.ia();if(c){for(var d=c.length,e=this.sa(),f=c?c:[],g=Math.cos(a),h=Math.sin(a),l=b[0],m=b[1],n=0,p=0;p<d;p+=e){var q=c[p]-l,r=c[p+1]-m;f[n++]=l+q*g-r*h;f[n++]=m+q*h+r*g;for(q=p+2;q<p+e;++q)f[n++]=c[q]}c&&f.length!=n&&(f.length=n);this.s()}};
k.scale=function(a,b,c){var d=b;void 0===d&&(d=a);var e=c;e||(e=kb(this.D()));if(c=this.ia()){b=c.length;for(var f=this.sa(),g=c?c:[],h=e[0],e=e[1],l=0,m=0;m<b;m+=f){var n=c[m]-h,p=c[m+1]-e;g[l++]=h+a*n;g[l++]=e+d*p;for(n=m+2;n<m+f;++n)g[l++]=c[n]}c&&g.length!=l&&(g.length=l);this.s()}};k.translate=function(a,b){var c=this.ia();c&&(nf(c,c.length,this.sa(),a,b,c),this.s())};function sf(a,b,c,d){for(var e=0,f=a[c-d],g=a[c-d+1];b<c;b+=d)var h=a[b],l=a[b+1],e=e+(g*h-f*l),f=h,g=l;return e/2}function tf(a,b,c,d){var e=0,f,g;f=0;for(g=c.length;f<g;++f){var h=c[f],e=e+sf(a,b,h,d);b=h}return e};function uf(a,b,c,d,e,f,g){var h=a[b],l=a[b+1],m=a[c]-h,n=a[c+1]-l;if(m||n)if(f=((e-h)*m+(f-l)*n)/(m*m+n*n),1<f)b=c;else if(0<f){for(e=0;e<d;++e)g[e]=Ea(a[b+e],a[c+e],f);g.length=d;return}for(e=0;e<d;++e)g[e]=a[b+e];g.length=d}function vf(a,b,c,d,e){var f=a[b],g=a[b+1];for(b+=d;b<c;b+=d){var h=a[b],l=a[b+1],f=Ba(f,g,h,l);f>e&&(e=f);f=h;g=l}return e}function wf(a,b,c,d,e){var f,g;f=0;for(g=c.length;f<g;++f){var h=c[f];e=vf(a,b,h,d,e);b=h}return e}
function xf(a,b,c,d,e,f,g,h,l,m,n){if(b==c)return m;var p;if(!e){p=Ba(g,h,a[b],a[b+1]);if(p<m){for(n=0;n<d;++n)l[n]=a[b+n];l.length=d;return p}return m}for(var q=n?n:[NaN,NaN],r=b+d;r<c;)if(uf(a,r-d,r,d,g,h,q),p=Ba(g,h,q[0],q[1]),p<m){m=p;for(n=0;n<d;++n)l[n]=q[n];l.length=d;r+=d}else r+=d*Math.max((Math.sqrt(p)-Math.sqrt(m))/e|0,1);if(f&&(uf(a,c-d,b,d,g,h,q),p=Ba(g,h,q[0],q[1]),p<m)){m=p;for(n=0;n<d;++n)l[n]=q[n];l.length=d}return m}
function yf(a,b,c,d,e,f,g,h,l,m,n){n=n?n:[NaN,NaN];var p,q;p=0;for(q=c.length;p<q;++p){var r=c[p];m=xf(a,b,r,d,e,f,g,h,l,m,n);b=r}return m};function zf(a,b){var c=0,d,e;d=0;for(e=b.length;d<e;++d)a[c++]=b[d];return c}function Af(a,b,c,d){var e,f;e=0;for(f=c.length;e<f;++e){var g=c[e],h;for(h=0;h<d;++h)a[b++]=g[h]}return b}function Bf(a,b,c,d,e){e=e?e:[];var f=0,g,h;g=0;for(h=c.length;g<h;++g)b=Af(a,b,c[g],d),e[f++]=b;e.length=f;return e};function Cf(a,b,c,d,e){e=void 0!==e?e:[];for(var f=0;b<c;b+=d)e[f++]=a.slice(b,b+d);e.length=f;return e}function Df(a,b,c,d,e){e=void 0!==e?e:[];var f=0,g,h;g=0;for(h=c.length;g<h;++g){var l=c[g];e[f++]=Cf(a,b,l,d,e[f]);b=l}e.length=f;return e};function Ef(a,b,c,d,e,f,g){var h=(c-b)/d;if(3>h){for(;b<c;b+=d)f[g++]=a[b],f[g++]=a[b+1];return g}var l=Array(h);l[0]=1;l[h-1]=1;c=[b,c-d];for(var m=0,n;0<c.length;){var p=c.pop(),q=c.pop(),r=0,v=a[q],x=a[q+1],y=a[p],A=a[p+1];for(n=q+d;n<p;n+=d){var B=Aa(a[n],a[n+1],v,x,y,A);B>r&&(m=n,r=B)}r>e&&(l[(m-b)/d]=1,q+d<m&&c.push(q,m),m+d<p&&c.push(m,p))}for(n=0;n<h;++n)l[n]&&(f[g++]=a[b+n*d],f[g++]=a[b+n*d+1]);return g}
function Ff(a,b,c,d,e,f,g,h){var l,m;l=0;for(m=c.length;l<m;++l){var n=c[l];a:{var p,q=a,r=n,v=d,x=e,y=f,A=g;if(b!=r){var B=x*Math.round(q[b]/x),aa=x*Math.round(q[b+1]/x);b+=v;y[A++]=B;y[A++]=aa;do if(p=x*Math.round(q[b]/x),g=x*Math.round(q[b+1]/x),b+=v,b==r){y[A++]=p;y[A++]=g;g=A;break a}while(p==B&&g==aa);for(;b<r;){var Ra,ra;Ra=x*Math.round(q[b]/x);ra=x*Math.round(q[b+1]/x);b+=v;if(Ra!=p||ra!=g){var Ka=p-B,C=g-aa,Na=Ra-B,wb=ra-aa;Ka*wb==C*Na&&(0>Ka&&Na<Ka||Ka==Na||0<Ka&&Na>Ka)&&(0>C&&wb<C||C==
wb||0<C&&wb>C)||(y[A++]=p,y[A++]=g,B=p,aa=g);p=Ra;g=ra}}y[A++]=p;y[A++]=g}g=A}h.push(g);b=n}return g};function Gf(a,b){of.call(this);this.c=this.j=-1;this.pa(a,b)}u(Gf,of);k=Gf.prototype;k.clone=function(){var a=new Gf(null);Hf(a,this.la,this.B.slice());return a};k.Hb=function(a,b,c,d){if(d<Pa(this.D(),a,b))return d;this.c!=this.g&&(this.j=Math.sqrt(vf(this.B,0,this.B.length,this.a,0)),this.c=this.g);return xf(this.B,0,this.B.length,this.a,this.j,!0,a,b,c,d)};k.jn=function(){return sf(this.B,0,this.B.length,this.a)};k.W=function(){return Cf(this.B,0,this.B.length,this.a)};
k.od=function(a){var b=[];b.length=Ef(this.B,0,this.B.length,this.a,a,b,0);a=new Gf(null);Hf(a,"XY",b);return a};k.S=function(){return"LinearRing"};k.Ya=function(){};k.pa=function(a,b){a?(rf(this,b,a,1),this.B||(this.B=[]),this.B.length=Af(this.B,0,a,this.a),this.s()):Hf(this,"XY",null)};function Hf(a,b,c){qf(a,b,c);a.s()};function E(a,b){of.call(this);this.pa(a,b)}u(E,of);k=E.prototype;k.clone=function(){var a=new E(null);a.ca(this.la,this.B.slice());return a};k.Hb=function(a,b,c,d){var e=this.B;a=Ba(a,b,e[0],e[1]);if(a<d){d=this.a;for(b=0;b<d;++b)c[b]=e[b];c.length=d;return a}return d};k.W=function(){return this.B?this.B.slice():[]};k.se=function(a){return Xa(this.B,a)};k.S=function(){return"Point"};k.Ya=function(a){return Sa(a,this.B[0],this.B[1])};
k.pa=function(a,b){a?(rf(this,b,a,0),this.B||(this.B=[]),this.B.length=zf(this.B,a),this.s()):this.ca("XY",null)};k.ca=function(a,b){qf(this,a,b);this.s()};function If(a,b,c,d,e){return!bb(e,function(e){return!Jf(a,b,c,d,e[0],e[1])})}function Jf(a,b,c,d,e,f){for(var g=0,h=a[c-d],l=a[c-d+1];b<c;b+=d){var m=a[b],n=a[b+1];l<=f?n>f&&0<(m-h)*(f-l)-(e-h)*(n-l)&&g++:n<=f&&0>(m-h)*(f-l)-(e-h)*(n-l)&&g--;h=m;l=n}return!!g}function Kf(a,b,c,d,e,f){if(!c.length||!Jf(a,b,c[0],d,e,f))return!1;var g;b=1;for(g=c.length;b<g;++b)if(Jf(a,c[b-1],c[b],d,e,f))return!1;return!0};function Lf(a,b,c,d,e,f,g){var h,l,m,n,p,q=e[f+1],r=[],v=c[0];m=a[v-d];p=a[v-d+1];for(h=b;h<v;h+=d){n=a[h];l=a[h+1];if(q<=p&&l<=q||p<=q&&q<=l)m=(q-p)/(l-p)*(n-m)+m,r.push(m);m=n;p=l}v=NaN;p=-Infinity;r.sort(ea);m=r[0];h=1;for(l=r.length;h<l;++h){n=r[h];var x=Math.abs(n-m);x>p&&(m=(m+n)/2,Kf(a,b,c,d,m,q)&&(v=m,p=x));m=n}isNaN(v)&&(v=e[f]);return g?(g.push(v,q),g):[v,q]};function Mf(a,b,c,d,e,f){for(var g=[a[b],a[b+1]],h=[],l;b+d<c;b+=d){h[0]=a[b+d];h[1]=a[b+d+1];if(l=e.call(f,g,h))return l;g[0]=h[0];g[1]=h[1]}return!1};function Nf(a,b,c,d,e){var f=Za(Ja(),a,b,c,d);return nb(e,f)?Ua(e,f)||f[0]>=e[0]&&f[2]<=e[2]||f[1]>=e[1]&&f[3]<=e[3]?!0:Mf(a,b,c,d,function(a,b){var c=!1,d=Va(e,a),f=Va(e,b);if(1===d||1===f)c=!0;else{var g=e[0],h=e[1],r=e[2],v=e[3],x=b[0],y=b[1],A=(y-a[1])/(x-a[0]);f&2&&!(d&2)&&(c=x-(y-v)/A,c=c>=g&&c<=r);c||!(f&4)||d&4||(c=y-(x-r)*A,c=c>=h&&c<=v);c||!(f&8)||d&8||(c=x-(y-h)/A,c=c>=g&&c<=r);c||!(f&16)||d&16||(c=y-(x-g)*A,c=c>=h&&c<=v)}return c}):!1}
function Of(a,b,c,d,e){var f=c[0];if(!(Nf(a,b,f,d,e)||Jf(a,b,f,d,e[0],e[1])||Jf(a,b,f,d,e[0],e[3])||Jf(a,b,f,d,e[2],e[1])||Jf(a,b,f,d,e[2],e[3])))return!1;if(1===c.length)return!0;b=1;for(f=c.length;b<f;++b)if(If(a,c[b-1],c[b],d,e))return!1;return!0};function Pf(a,b,c,d){for(var e=0,f=a[c-d],g=a[c-d+1];b<c;b+=d)var h=a[b],l=a[b+1],e=e+(h-f)*(l+g),f=h,g=l;return 0<e}function Qf(a,b,c,d){var e=0;d=void 0!==d?d:!1;var f,g;f=0;for(g=b.length;f<g;++f){var h=b[f],e=Pf(a,e,h,c);if(!f){if(d&&e||!d&&!e)return!1}else if(d&&!e||!d&&e)return!1;e=h}return!0}
function Rf(a,b,c,d,e){e=void 0!==e?e:!1;var f,g;f=0;for(g=c.length;f<g;++f){var h=c[f],l=Pf(a,b,h,d);if(f?e&&!l||!e&&l:e&&l||!e&&!l)for(var l=a,m=h,n=d;b<m-n;){var p;for(p=0;p<n;++p){var q=l[b+p];l[b+p]=l[m-n+p];l[m-n+p]=q}b+=n;m-=n}b=h}return b}function Sf(a,b,c,d){var e=0,f,g;f=0;for(g=b.length;f<g;++f)e=Rf(a,e,b[f],c,d);return e};function F(a,b){of.call(this);this.c=[];this.v=-1;this.A=null;this.I=this.C=this.G=-1;this.j=null;this.pa(a,b)}u(F,of);k=F.prototype;k.kk=function(a){this.B?ha(this.B,a.ia()):this.B=a.ia().slice();this.c.push(this.B.length);this.s()};k.clone=function(){var a=new F(null);a.ca(this.la,this.B.slice(),this.c.slice());return a};
k.Hb=function(a,b,c,d){if(d<Pa(this.D(),a,b))return d;this.C!=this.g&&(this.G=Math.sqrt(wf(this.B,0,this.c,this.a,0)),this.C=this.g);return yf(this.B,0,this.c,this.a,this.G,!0,a,b,c,d)};k.Sc=function(a,b){return Kf(this.gc(),0,this.c,this.a,a,b)};k.mn=function(){return tf(this.gc(),0,this.c,this.a)};k.W=function(a){var b;void 0!==a?(b=this.gc().slice(),Rf(b,0,this.c,this.a,a)):b=this.B;return Df(b,0,this.c,this.a)};k.Sb=function(){return this.c};
function Tf(a){if(a.v!=a.g){var b=kb(a.D());a.A=Lf(a.gc(),0,a.c,a.a,b,0);a.v=a.g}return a.A}k.Ok=function(){return new E(Tf(this))};k.Uk=function(){return this.c.length};k.vh=function(a){if(0>a||this.c.length<=a)return null;var b=new Gf(null);Hf(b,this.la,this.B.slice(a?this.c[a-1]:0,this.c[a]));return b};k.Oc=function(){var a=this.la,b=this.B,c=this.c,d=[],e=0,f,g;f=0;for(g=c.length;f<g;++f){var h=c[f],l=new Gf(null);Hf(l,a,b.slice(e,h));d.push(l);e=h}return d};
k.gc=function(){if(this.I!=this.g){var a=this.B;Qf(a,this.c,this.a)?this.j=a:(this.j=a.slice(),this.j.length=Rf(this.j,0,this.c,this.a));this.I=this.g}return this.j};k.od=function(a){var b=[],c=[];b.length=Ff(this.B,0,this.c,this.a,Math.sqrt(a),b,0,c);a=new F(null);a.ca("XY",b,c);return a};k.S=function(){return"Polygon"};k.Ya=function(a){return Of(this.gc(),0,this.c,this.a,a)};
k.pa=function(a,b){if(a){rf(this,b,a,2);this.B||(this.B=[]);var c=Bf(this.B,0,a,this.a,this.c);this.B.length=c.length?c[c.length-1]:0;this.s()}else this.ca("XY",null,this.c)};k.ca=function(a,b,c){qf(this,a,b);this.c=c;this.s()};function Uf(a,b,c,d){var e=d?d:32;d=[];var f;for(f=0;f<e;++f)ha(d,a.offset(b,c,2*Math.PI*f/e));d.push(d[0],d[1]);a=new F(null);a.ca("XY",d,[d.length]);return a}
function Vf(a){var b=a[0],c=a[1],d=a[2];a=a[3];b=[b,c,b,a,d,a,d,c,b,c];c=new F(null);c.ca("XY",b,[b.length]);return c}function Wf(a,b,c){var d=b?b:32,e=a.sa();b=a.la;for(var f=new F(null,b),d=e*(d+1),e=Array(d),g=0;g<d;g++)e[g]=0;f.ca(b,e,[e.length]);Xf(f,a.za(),a.Yd(),c);return f}function Xf(a,b,c,d){var e=a.ia(),f=a.la,g=a.sa(),h=a.Sb(),l=e.length/g-1;d=d?d:0;for(var m,n,p=0;p<=l;++p)n=p*g,m=d+2*Da(p,l)*Math.PI/l,e[n]=b[0]+c*Math.cos(m),e[n+1]=b[1]+c*Math.sin(m);a.ca(f,e,h)};function G(a){Qc.call(this);a=qb({},a);this.j=[0,0];this.c=[];this.vf=this.vf.bind(this);this.o=Zb(a.projection);Yf(this,a)}u(G,Qc);
function Yf(a,b){var c={};c.center=void 0!==b.center?b.center:null;var d,e,f,g=void 0!==b.minZoom?b.minZoom:0;d=void 0!==b.maxZoom?b.maxZoom:28;var h=void 0!==b.zoomFactor?b.zoomFactor:2;if(void 0!==b.resolutions)d=b.resolutions,e=d[0],f=d[d.length-1],d=Pe(d);else{e=Zb(b.projection);f=e.D();var l=(f?Math.max(ib(f),jb(f)):360*xb.degrees/e.uc())/256/Math.pow(2,0),m=l/Math.pow(2,28);e=b.maxResolution;void 0!==e?g=0:e=l/Math.pow(h,g);f=b.minResolution;void 0===f&&(f=void 0!==b.maxZoom?void 0!==b.maxResolution?
e/Math.pow(h,d):l/Math.pow(h,d):m);d=g+Math.floor(Math.log(e/f)/Math.log(h));f=e/Math.pow(h,d-g);d=Qe(h,e,d-g)}a.a=e;a.i=f;a.C=h;a.f=b.resolutions;a.l=g;(void 0!==b.enableRotation?b.enableRotation:1)?(g=b.constrainRotation,g=void 0===g||!0===g?Ue():!1===g?Se:"number"===typeof g?Te(g):Se):g=Re;a.v=new gd(void 0!==b.extent?yc(b.extent):zc,d,g);void 0!==b.resolution?c.resolution=b.resolution:void 0!==b.zoom&&(c.resolution=a.constrainResolution(a.a,b.zoom-a.l));c.rotation=void 0!==b.rotation?b.rotation:
0;a.H(c);a.A=b}function Zf(a,b){var c=qb({},a.A);void 0!==c.resolution?c.resolution=a.Ra():c.zoom=a.Ah();c.center=a.za();c.rotation=a.Sa();return qb({},c,b)}k=G.prototype;
k.animate=function(a){var b=Date.now(),c=this.za().slice(),d=this.Ra(),e=this.Sa(),f=arguments.length,g;1<f&&"function"===typeof arguments[f-1]&&(g=arguments[f-1],--f);for(var h=[],l=0;l<f;++l){var m=arguments[l],n={start:b,complete:!1,anchor:m.anchor,duration:void 0!==m.duration?m.duration:1E3,easing:m.easing||qd};m.center&&(n.Jg=c,n.Lg=m.center,c=n.Lg);void 0!==m.zoom?(n.sf=d,n.Bd=this.constrainResolution(this.a,m.zoom-this.l,0),d=n.Bd):m.resolution&&(n.sf=d,n.Bd=m.resolution,d=n.Bd);void 0!==m.rotation&&
(n.Kg=e,n.tf=m.rotation,e=n.tf);n.jd=g;b+=n.duration;h.push(n)}this.c.push(h);$f(this,0,1);this.vf()};k.Kc=function(){return 0<ag(this)[0]};k.kd=function(){$f(this,0,-ag(this)[0]);for(var a=0,b=this.c.length;a<b;++a){var c=this.c[a];c[0].jd&&c[0].jd(!1)}this.c.length=0};
k.vf=function(){void 0!==this.u&&(cancelAnimationFrame(this.u),this.u=void 0);if(this.Kc()){for(var a=Date.now(),b=!1,c=this.c.length-1;0<=c;--c){for(var d=this.c[c],e=!0,f=0,g=d.length;f<g;++f){var h=d[f];if(!h.complete){b=a-h.start;b=0<h.duration?b/h.duration:1;1<=b?(h.complete=!0,b=1):e=!1;b=h.easing(b);if(h.Jg){var l=h.Jg[0],m=h.Jg[1];this.set("center",[l+b*(h.Lg[0]-l),m+b*(h.Lg[1]-m)])}h.sf&&h.Bd&&(l=1===b?h.Bd:h.sf+b*(h.Bd-h.sf),h.anchor&&this.set("center",bg(this,l,h.anchor)),this.set("resolution",
l));void 0!==h.Kg&&void 0!==h.tf&&(b=1===b?h.tf:h.Kg+b*(h.tf-h.Kg),h.anchor&&this.set("center",cg(this,b,h.anchor)),this.set("rotation",b));b=!0;if(!h.complete)break}}e&&(this.c[c]=null,$f(this,0,-1),(d=d[0].jd)&&d(!0))}this.c=this.c.filter(Boolean);b&&void 0===this.u&&(this.u=requestAnimationFrame(this.vf))}};function cg(a,b,c){var d,e=a.za();void 0!==e&&(d=[e[0]-c[0],e[1]-c[1]],cf(d,b-a.Sa()),Xe(d,c));return d}
function bg(a,b,c){var d,e=a.za();a=a.Ra();void 0!==e&&void 0!==a&&(d=[c[0]-b*(c[0]-e[0])/a,c[1]-b*(c[1]-e[1])/a]);return d}function dg(a){var b=[100,100];a='.ol-viewport[data-view="'+w(a)+'"]';if(a=document.querySelector(a))a=getComputedStyle(a),b[0]=parseInt(a.width,10),b[1]=parseInt(a.height,10);return b}k.Gc=function(a){return this.v.center(a)};k.constrainResolution=function(a,b,c){return this.v.resolution(a,b||0,c||0)};k.constrainRotation=function(a,b){return this.v.rotation(a,b||0)};k.za=function(){return this.get("center")};
function ag(a,b){return void 0!==b?(b[0]=a.j[0],b[1]=a.j[1],b):a.j.slice()}k.hd=function(a){a=a||dg(this);var b=this.za();sa(b,1);var c=this.Ra();sa(void 0!==c,2);var d=this.Sa();sa(void 0!==d,3);return lb(b,c,d,a)};k.Hm=function(){return this.a};k.Jm=function(){return this.i};k.Im=function(){return this.Be(this.i)};k.Up=function(a){Yf(this,Zf(this,{maxZoom:a}))};k.Km=function(){return this.Be(this.a)};k.Vp=function(a){Yf(this,Zf(this,{minZoom:a}))};k.Lm=function(){return this.o};k.Ra=function(){return this.get("resolution")};
k.Mm=function(){return this.f};function eg(a,b){return Math.max(ib(a)/b[0],jb(a)/b[1])}function fg(a){var b=a.a,c=Math.log(b/a.i)/Math.log(2);return function(a){return b/Math.pow(2,a*c)}}k.Sa=function(){return this.get("rotation")};function gg(a){var b=a.a,c=Math.log(b/a.i)/Math.log(2);return function(a){return Math.log(b/a)/Math.log(2)/c}}k.V=function(){var a=this.za(),b=this.o,c=this.Ra(),d=this.Sa();return{center:a.slice(),projection:void 0!==b?b:null,resolution:c,rotation:d}};
k.Ah=function(){var a,b=this.Ra();void 0!==b&&(a=this.Be(b));return a};k.Be=function(a){var b;if(a>=this.i&&a<=this.a){b=this.l||0;var c,d;if(this.f){d=ga(this.f,a,1);b+=d;if(d==this.f.length-1)return b;c=this.f[d];d=c/this.f[d+1]}else c=this.a,d=this.C;b+=Math.log(c/a)/Math.log(d)}return b};
k.Mf=function(a,b){var c=b||{},d=c.size;d||(d=dg(this));var e;a instanceof of?"Circle"===a.S()?(a=a.D(),e=Vf(a),e.rotate(this.Sa(),kb(a))):e=a:(sa(Array.isArray(a),24),sa(!hb(a),25),e=Vf(a));var f=c.padding?c.padding:[0,0,0,0],g=void 0!==c.constrainResolution?c.constrainResolution:!0,h=void 0!==c.nearest?c.nearest:!1,l;void 0!==c.minResolution?l=c.minResolution:void 0!==c.maxZoom?l=this.constrainResolution(this.a,c.maxZoom-this.l,0):l=0;var m=e.ia(),n=this.Sa(),p=Math.cos(-n),n=Math.sin(-n),q=Infinity,
r=Infinity,v=-Infinity,x=-Infinity;e=e.sa();for(var y=0,A=m.length;y<A;y+=e)var B=m[y]*p-m[y+1]*n,aa=m[y]*n+m[y+1]*p,q=Math.min(q,B),r=Math.min(r,aa),v=Math.max(v,B),x=Math.max(x,aa);d=eg([q,r,v,x],[d[0]-f[1]-f[3],d[1]-f[0]-f[2]]);d=isNaN(d)?l:Math.max(d,l);g&&(g=this.constrainResolution(d,0,0),!h&&g<d&&(g=this.constrainResolution(g,-1,0)),d=g);n=-n;h=(q+v)/2+(f[1]-f[3])/2*d;f=(r+x)/2+(f[0]-f[2])/2*d;p=[h*p-f*n,f*p+h*n];void 0!==c.duration?this.animate({resolution:d,center:p,duration:c.duration,easing:c.easing}):
(this.$c(d),this.lb(p))};k.qk=function(a,b,c){var d=this.Sa(),e=Math.cos(-d),d=Math.sin(-d),f=a[0]*e-a[1]*d;a=a[1]*e+a[0]*d;var g=this.Ra(),f=f+(b[0]/2-c[0])*g;a+=(c[1]-b[1]/2)*g;d=-d;this.lb([f*e-a*d,a*e+f*d])};function hg(a){return!!a.za()&&void 0!==a.Ra()}k.rotate=function(a,b){if(void 0!==b){var c=cg(this,a,b);this.lb(c)}this.Ne(a)};k.lb=function(a){this.set("center",a);this.Kc()&&this.kd()};function $f(a,b,c){a.j[b]+=c;a.s()}k.$c=function(a){this.set("resolution",a);this.Kc()&&this.kd()};
k.Ne=function(a){this.set("rotation",a);this.Kc()&&this.kd()};k.aq=function(a){a=this.constrainResolution(this.a,a-this.l,0);this.$c(a)};function ig(a,b,c){this.i=a;this.c=b;this.f=c;this.b=[];this.a=this.g=0}function jg(a){a.b.length=0;a.g=0;a.a=0};function kg(a){Qc.call(this);this.v=null;this.Ia(!0);this.handleEvent=a.handleEvent}u(kg,Qc);kg.prototype.c=function(){return this.get("active")};kg.prototype.i=function(){return this.v};kg.prototype.Ia=function(a){this.set("active",a)};kg.prototype.setMap=function(a){this.v=a};function lg(a,b,c,d){if(void 0!==b){var e=a.Sa(),f=a.za();void 0!==e&&f&&0<d?a.animate({rotation:b,anchor:c,duration:d,easing:pd}):a.rotate(b,c)}}
function mg(a,b,c,d){var e=a.Ra();b=a.constrainResolution(e,b,0);if(c&&void 0!==b&&b!==e){var f=a.za();c=bg(a,b,c);c=a.Gc(c);c=[(b*f[0]-e*c[0])/(b-e),(b*f[1]-e*c[1])/(b-e)]}ng(a,b,c,d)}function ng(a,b,c,d){if(b){var e=a.Ra(),f=a.za();void 0!==e&&f&&b!==e&&d?a.animate({resolution:b,anchor:c,duration:d,easing:pd}):(c&&(c=bg(a,b,c),a.lb(c)),a.$c(b))}};function og(a){a=a?a:{};this.a=a.delta?a.delta:1;kg.call(this,{handleEvent:pg});this.f=void 0!==a.duration?a.duration:250}u(og,kg);function pg(a){var b=!1,c=a.originalEvent;if("dblclick"==a.type){var b=a.coordinate,c=c.shiftKey?-this.a:this.a,d=a.map.$();mg(d,c,b,this.f);a.preventDefault();b=!0}return!b};function qg(a){a=a.originalEvent;return a.altKey&&!(a.metaKey||a.ctrlKey)&&a.shiftKey}function rg(a){a=a.originalEvent;return!a.button&&!(Rd&&Sd&&a.ctrlKey)}function sg(a){return"pointermove"==a.type}function tg(a){return"singleclick"==a.type}function vg(a){a=a.originalEvent;return!a.altKey&&!(a.metaKey||a.ctrlKey)&&!a.shiftKey}function wg(a){a=a.originalEvent;return!a.altKey&&!(a.metaKey||a.ctrlKey)&&a.shiftKey}
function xg(a){a=a.originalEvent.target.tagName;return"INPUT"!==a&&"SELECT"!==a&&"TEXTAREA"!==a}function yg(a){sa(a.b,56);return"mouse"==a.b.pointerType}function zg(a){a=a.b;return a.isPrimary&&0===a.button};function Ag(a){a=a?a:{};kg.call(this,{handleEvent:a.handleEvent?a.handleEvent:Bg});this.wf=a.handleDownEvent?a.handleDownEvent:kf;this.Ef=a.handleDragEvent?a.handleDragEvent:oa;this.Ff=a.handleMoveEvent?a.handleMoveEvent:oa;this.nk=a.handleUpEvent?a.handleUpEvent:kf;this.A=!1;this.ea={};this.l=[]}u(Ag,kg);function Cg(a){for(var b=a.length,c=0,d=0,e=0;e<b;e++)c+=a[e].clientX,d+=a[e].clientY;return[c/b,d/b]}
function Bg(a){if(!(a instanceof Kd))return!0;var b=!1,c=a.type;if("pointerdown"===c||"pointerdrag"===c||"pointerup"===c)c=a.b,"pointerup"==a.type?delete this.ea[c.pointerId]:"pointerdown"==a.type?this.ea[c.pointerId]=c:c.pointerId in this.ea&&(this.ea[c.pointerId]=c),this.l=sb(this.ea);this.A?"pointerdrag"==a.type?this.Ef(a):"pointerup"==a.type&&(this.A=this.nk(a)&&0<this.l.length):"pointerdown"==a.type?(this.A=a=this.wf(a),b=this.bd(a)):"pointermove"==a.type&&this.Ff(a);return!b}
Ag.prototype.bd=function(a){return a};function Dg(a){Ag.call(this,{handleDownEvent:Eg,handleDragEvent:Fg,handleUpEvent:Gg});a=a?a:{};this.a=a.kinetic;this.f=null;this.u=a.condition?a.condition:vg;this.j=!1}u(Dg,Ag);function Fg(a){var b=this.l,c=Cg(b);if(b.length==this.o){if(this.a&&this.a.b.push(c[0],c[1],Date.now()),this.f){var d=this.f[0]-c[0],e=c[1]-this.f[1];a=a.map.$();var f=a.V(),d=[d,e];df(d,f.resolution);cf(d,f.rotation);Xe(d,f.center);d=a.Gc(d);a.lb(d)}}else this.a&&jg(this.a);this.f=c;this.o=b.length}
function Gg(a){var b=a.map;a=b.$();if(this.l.length)return this.a&&jg(this.a),this.f=null,!0;var c;if(c=!this.j&&this.a)if(c=this.a,6>c.b.length)c=!1;else{var d=Date.now()-c.f,e=c.b.length-3;if(c.b[e+2]<d)c=!1;else{for(var f=e-3;0<f&&c.b[f+2]>d;)f-=3;var d=c.b[e+2]-c.b[f+2],g=c.b[e]-c.b[f],e=c.b[e+1]-c.b[f+1];c.g=Math.atan2(e,g);c.a=Math.sqrt(g*g+e*e)/d;c=c.a>c.c}}c&&(c=this.a,c=(c.c-c.a)/c.i,e=this.a.g,f=a.za(),f=b.Ka(f),b=b.Xa([f[0]-c*Math.cos(e),f[1]-c*Math.sin(e)]),a.animate({center:a.Gc(b),duration:500,
easing:pd}));$f(a,1,-1);return!1}function Eg(a){if(0<this.l.length&&this.u(a)){var b=a.map.$();this.f=null;this.A||$f(b,1,1);ag(b)[0]&&b.lb(a.frameState.viewState.center);this.a&&jg(this.a);this.j=1<this.l.length;return!0}return!1}Dg.prototype.bd=kf;function Hg(a){a=a?a:{};Ag.call(this,{handleDownEvent:Ig,handleDragEvent:Jg,handleUpEvent:Kg});this.f=a.condition?a.condition:qg;this.a=void 0;this.j=void 0!==a.duration?a.duration:250}u(Hg,Ag);function Jg(a){if(yg(a)){var b=a.map,c=b.Nb();a=a.pixel;c=Math.atan2(c[1]/2-a[1],a[0]-c[0]/2);if(void 0!==this.a){a=c-this.a;var b=b.$(),d=b.Sa();lg(b,d-a)}this.a=c}}function Kg(a){if(!yg(a))return!0;a=a.map.$();$f(a,1,-1);var b=a.Sa(),c=this.j,b=a.constrainRotation(b,0);lg(a,b,void 0,c);return!1}
function Ig(a){return yg(a)&&rg(a)&&this.f(a)?($f(a.map.$(),1,1),this.a=void 0,!0):!1}Hg.prototype.bd=kf;function Lg(a){this.Ic=null;this.a=document.createElement("div");this.a.style.position="absolute";this.a.className="ol-box "+a;this.g=this.c=this.b=null}u(Lg,Jc);Lg.prototype.ra=function(){this.setMap(null)};function Mg(a){var b=a.c,c=a.g;a=a.a.style;a.left=Math.min(b[0],c[0])+"px";a.top=Math.min(b[1],c[1])+"px";a.width=Math.abs(c[0]-b[0])+"px";a.height=Math.abs(c[1]-b[1])+"px"}
Lg.prototype.setMap=function(a){if(this.b){this.b.A.removeChild(this.a);var b=this.a.style;b.left=b.top=b.width=b.height="inherit"}(this.b=a)&&this.b.A.appendChild(this.a)};function Ng(a){var b=a.c,c=a.g,b=[b,[b[0],c[1]],c,[c[0],b[1]]].map(a.b.Xa,a.b);b[4]=b[0].slice();a.Ic?a.Ic.pa([b]):a.Ic=new F([b])}Lg.prototype.U=function(){return this.Ic};function Og(a){Ag.call(this,{handleDownEvent:Pg,handleDragEvent:Qg,handleUpEvent:Rg});a=a?a:{};this.a=new Lg(a.className||"ol-dragbox");this.u=void 0!==a.minArea?a.minArea:64;this.f=null;this.C=a.condition?a.condition:jf;this.o=a.boxEndCondition?a.boxEndCondition:Sg}u(Og,Ag);function Sg(a,b,c){a=c[0]-b[0];b=c[1]-b[1];return a*a+b*b>=this.u}function Qg(a){if(yg(a)){var b=this.a,c=a.pixel;b.c=this.f;b.g=c;Ng(b);Mg(b);this.b(new Tg(Ug,a.coordinate,a))}}Og.prototype.U=function(){return this.a.U()};
Og.prototype.j=oa;function Rg(a){if(!yg(a))return!0;this.a.setMap(null);this.o(a,this.f,a.pixel)&&(this.j(a),this.b(new Tg(Vg,a.coordinate,a)));return!1}function Pg(a){if(yg(a)&&rg(a)&&this.C(a)){this.f=a.pixel;this.a.setMap(a.map);var b=this.a,c=this.f;b.c=this.f;b.g=c;Ng(b);Mg(b);this.b(new Tg(Wg,a.coordinate,a));return!0}return!1}var Wg="boxstart",Ug="boxdrag",Vg="boxend";function Tg(a,b,c){Lc.call(this,a);this.coordinate=b;this.mapBrowserEvent=c}u(Tg,Lc);function Xg(a){a=a?a:{};var b=a.condition?a.condition:wg;this.G=void 0!==a.duration?a.duration:200;this.I=void 0!==a.out?a.out:!1;Og.call(this,{condition:b,className:a.className||"ol-dragzoom"})}u(Xg,Og);
Xg.prototype.j=function(){var a=this.v,b=a.$(),c=a.Nb(),d=this.U().D();if(this.I){var e=b.hd(c),d=[a.Ka(cb(d)),a.Ka(eb(d))],a=Wa(Infinity,Infinity,-Infinity,-Infinity,void 0),f,g;f=0;for(g=d.length;f<g;++f)La(a,d[f]);ob(e,1/eg(a,c));d=e}c=b.constrainResolution(eg(d,c));e=kb(d);e=b.Gc(e);b.animate({resolution:c,center:e,duration:this.G,easing:pd})};function Yg(a){kg.call(this,{handleEvent:Zg});a=a||{};this.a=function(a){return vg(a)&&xg(a)};this.f=a.condition?a.condition:this.a;this.j=void 0!==a.duration?a.duration:100;this.l=void 0!==a.pixelDelta?a.pixelDelta:128}u(Yg,kg);
function Zg(a){var b=!1;if("keydown"==a.type){var c=a.originalEvent.keyCode;if(this.f(a)&&(40==c||37==c||39==c||38==c)){var b=a.map.$(),d=b.Ra()*this.l,e=0,f=0;40==c?f=-d:37==c?e=-d:39==c?e=d:f=d;d=[e,f];cf(d,b.Sa());c=this.j;if(e=b.za())d=b.Gc([e[0]+d[0],e[1]+d[1]]),c?b.animate({duration:c,easing:rd,center:d}):b.lb(d);a.preventDefault();b=!0}}return!b};function $g(a){kg.call(this,{handleEvent:ah});a=a?a:{};this.f=a.condition?a.condition:xg;this.a=a.delta?a.delta:1;this.j=void 0!==a.duration?a.duration:100}u($g,kg);function ah(a){var b=!1;if("keydown"==a.type||"keypress"==a.type){var c=a.originalEvent.charCode;!this.f(a)||43!=c&&45!=c||(b=43==c?this.a:-this.a,c=a.map.$(),mg(c,b,void 0,this.j),a.preventDefault(),b=!0)}return!b};function bh(a){kg.call(this,{handleEvent:ch});a=a||{};this.j=0;this.A=void 0!==a.duration?a.duration:250;this.ea=void 0!==a.timeout?a.timeout:80;this.C=void 0!==a.useAnchor?a.useAnchor:!0;this.Z=a.constrainResolution||!1;this.a=null;this.o=this.l=this.u=this.f=void 0}u(bh,kg);
function ch(a){var b=a.type;if("wheel"!==b&&"mousewheel"!==b)return!0;a.preventDefault();var b=a.map,c=a.originalEvent;this.C&&(this.a=a.coordinate);var d;"wheel"==a.type?(d=c.deltaY,Pd&&c.deltaMode===WheelEvent.DOM_DELTA_PIXEL&&(d/=Td),c.deltaMode===WheelEvent.DOM_DELTA_LINE&&(d*=40)):"mousewheel"==a.type&&(d=-c.wheelDeltaY,Qd&&(d/=3));if(0===d)return!1;a=Date.now();void 0===this.f&&(this.f=a);if(!this.l||400<a-this.f)this.l=4>Math.abs(d)?dh:eh;if(this.l===dh){b=b.$();this.o?clearTimeout(this.o):
$f(b,1,1);this.o=setTimeout(this.G.bind(this),400);var c=b.Ra()*Math.pow(2,d/300),e=b.i,f=b.a,g=0;c<e?(c=Math.max(c,e/1.5),g=1):c>f&&(c=Math.min(c,1.5*f),g=-1);if(this.a){var h=bg(b,c,this.a);b.lb(b.Gc(h))}b.$c(c);!g&&this.Z&&b.animate({resolution:b.constrainResolution(c,0<d?-1:1),easing:pd,anchor:this.a,duration:this.A});0<g?b.animate({resolution:e,easing:pd,anchor:this.a,duration:500}):0>g&&b.animate({resolution:f,easing:pd,anchor:this.a,duration:500});this.f=a;return!1}this.j+=d;d=Math.max(this.ea-
(a-this.f),0);clearTimeout(this.u);this.u=setTimeout(this.I.bind(this,b),d);return!1}bh.prototype.G=function(){this.o=void 0;$f(this.v.$(),1,-1)};bh.prototype.I=function(a){a=a.$();a.Kc()&&a.kd();mg(a,-xa(this.j,-1,1),this.a,this.A);this.l=void 0;this.j=0;this.a=null;this.u=this.f=void 0};bh.prototype.T=function(a){this.C=a;a||(this.a=null)};var dh="trackpad",eh="wheel";function fh(a){Ag.call(this,{handleDownEvent:gh,handleDragEvent:hh,handleUpEvent:ih});a=a||{};this.f=null;this.j=void 0;this.a=!1;this.o=0;this.C=void 0!==a.threshold?a.threshold:.3;this.u=void 0!==a.duration?a.duration:250}u(fh,Ag);
function hh(a){var b=0,c=this.l[0],d=this.l[1],c=Math.atan2(d.clientY-c.clientY,d.clientX-c.clientX);void 0!==this.j&&(b=c-this.j,this.o+=b,!this.a&&Math.abs(this.o)>this.C&&(this.a=!0));this.j=c;a=a.map;c=a.c.getBoundingClientRect();d=Cg(this.l);d[0]-=c.left;d[1]-=c.top;this.f=a.Xa(d);this.a&&(c=a.$(),d=c.Sa(),a.render(),lg(c,d+b,this.f))}function ih(a){if(2>this.l.length){a=a.map.$();$f(a,1,-1);if(this.a){var b=a.Sa(),c=this.f,d=this.u,b=a.constrainRotation(b,0);lg(a,b,c,d)}return!1}return!0}
function gh(a){return 2<=this.l.length?(a=a.map,this.f=null,this.j=void 0,this.a=!1,this.o=0,this.A||$f(a.$(),1,1),!0):!1}fh.prototype.bd=kf;function jh(a){Ag.call(this,{handleDownEvent:kh,handleDragEvent:lh,handleUpEvent:nh});a=a?a:{};this.o=a.constrainResolution||!1;this.f=null;this.u=void 0!==a.duration?a.duration:400;this.a=void 0;this.j=1}u(jh,Ag);
function lh(a){var b=1,c=this.l[0],d=this.l[1],e=c.clientX-d.clientX,c=c.clientY-d.clientY,e=Math.sqrt(e*e+c*c);void 0!==this.a&&(b=this.a/e);this.a=e;a=a.map;var e=a.$(),d=e.Ra(),f=e.a,g=e.i,c=d*b;c>f?(b=f/d,c=f):c<g&&(b=g/d,c=g);1!=b&&(this.j=b);b=a.c.getBoundingClientRect();d=Cg(this.l);d[0]-=b.left;d[1]-=b.top;this.f=a.Xa(d);a.render();ng(e,c,this.f)}
function nh(a){if(2>this.l.length){a=a.map.$();$f(a,1,-1);var b=a.Ra();if(this.o||b<a.i||b>a.a){var c=this.f,d=this.u,b=a.constrainResolution(b,0,this.j-1);ng(a,b,c,d)}return!1}return!0}function kh(a){return 2<=this.l.length?(a=a.map,this.f=null,this.a=void 0,this.j=1,this.A||$f(a.$(),1,1),!0):!1}jh.prototype.bd=kf;function oh(a){a=a?a:{};var b=new D,c=new ig(-.005,.05,100);(void 0!==a.altShiftDragRotate?a.altShiftDragRotate:1)&&b.push(new Hg);(void 0!==a.doubleClickZoom?a.doubleClickZoom:1)&&b.push(new og({delta:a.zoomDelta,duration:a.zoomDuration}));(void 0!==a.dragPan?a.dragPan:1)&&b.push(new Dg({kinetic:c}));(void 0!==a.pinchRotate?a.pinchRotate:1)&&b.push(new fh);(void 0!==a.pinchZoom?a.pinchZoom:1)&&b.push(new jh({constrainResolution:a.constrainResolution,duration:a.zoomDuration}));if(void 0!==a.keyboard?
a.keyboard:1)b.push(new Yg),b.push(new $g({delta:a.zoomDelta,duration:a.zoomDuration}));(void 0!==a.mouseWheelZoom?a.mouseWheelZoom:1)&&b.push(new bh({constrainResolution:a.constrainResolution,duration:a.zoomDuration}));(void 0!==a.shiftDragZoom?a.shiftDragZoom:1)&&b.push(new Xg({duration:a.zoomDuration}));return b};function ph(a){Qc.call(this);var b=qb({},a);b.opacity=void 0!==a.opacity?a.opacity:1;b.visible=void 0!==a.visible?a.visible:!0;b.zIndex=void 0!==a.zIndex?a.zIndex:0;b.maxResolution=void 0!==a.maxResolution?a.maxResolution:Infinity;b.minResolution=void 0!==a.minResolution?a.minResolution:0;this.H(b);this.a={layer:this,Ie:!0}}u(ph,Qc);
function qh(a){a.a.opacity=xa(a.jc(),0,1);a.a.uj=a.Vf();a.a.visible=a.Lb();a.a.extent=a.D();a.a.zIndex=a.Aa();a.a.maxResolution=a.hc();a.a.minResolution=Math.max(a.ic(),0);return a.a}k=ph.prototype;k.D=function(){return this.get("extent")};k.hc=function(){return this.get("maxResolution")};k.ic=function(){return this.get("minResolution")};k.jc=function(){return this.get("opacity")};k.Lb=function(){return this.get("visible")};k.Aa=function(){return this.get("zIndex")};
k.xc=function(a){this.set("extent",a)};k.Cc=function(a){this.set("maxResolution",a)};k.Dc=function(a){this.set("minResolution",a)};k.yc=function(a){this.set("opacity",a)};k.zc=function(a){this.set("visible",a)};k.Xb=function(a){this.set("zIndex",a)};function rh(a){var b=a||{};a=qb({},b);delete a.layers;b=b.layers;ph.call(this,a);this.i=[];this.c={};z(this,Sc(sh),this.Cl,this);b?Array.isArray(b)?b=new D(b.slice(),{unique:!0}):sa(b instanceof D,43):b=new D(void 0,{unique:!0});this.pi(b)}u(rh,ph);k=rh.prototype;k.Gd=function(){};k.Ee=function(){this.Lb()&&this.s()};
k.Cl=function(){this.i.forEach(Bc);this.i.length=0;var a=this.sd();this.i.push(z(a,"add",this.Bl,this),z(a,"remove",this.Dl,this));for(var b in this.c)this.c[b].forEach(Bc);rb(this.c);var a=a.a,c,d;b=0;for(c=a.length;b<c;b++)d=a[b],this.c[w(d).toString()]=[z(d,"propertychange",this.Ee,this),z(d,"change",this.Ee,this)];this.s()};k.Bl=function(a){a=a.element;var b=w(a).toString();this.c[b]=[z(a,"propertychange",this.Ee,this),z(a,"change",this.Ee,this)];this.s()};
k.Dl=function(a){a=w(a.element).toString();this.c[a].forEach(Bc);delete this.c[a];this.s()};k.sd=function(){return this.get(sh)};k.pi=function(a){this.set(sh,a)};
k.Tf=function(a){var b=void 0!==a?a:[],c=b.length;this.sd().forEach(function(a){a.Tf(b)});a=qh(this);var d,e;for(d=b.length;c<d;c++)e=b[c],e.opacity*=a.opacity,e.visible=e.visible&&a.visible,e.maxResolution=Math.min(e.maxResolution,a.maxResolution),e.minResolution=Math.max(e.minResolution,a.minResolution),void 0!==a.extent&&(e.extent=void 0!==e.extent?mb(e.extent,a.extent):a.extent);return b};k.Vf=function(){return"ready"};var sh="layers";function th(a){var b=qb({},a);delete b.source;ph.call(this,b);this.v=this.o=this.l=null;a.map&&this.setMap(a.map);z(this,Sc("source"),this.Pl,this);this.ad(a.source?a.source:null)}u(th,ph);function uh(a,b){return a.visible&&b>=a.minResolution&&b<a.maxResolution}k=th.prototype;k.Tf=function(a){a=a?a:[];a.push(qh(this));return a};k.ka=function(){return this.get("source")||null};k.Vf=function(){var a=this.ka();return a?a.V():"undefined"};k.Ln=function(){this.s()};
k.Pl=function(){this.v&&(Bc(this.v),this.v=null);var a=this.ka();a&&(this.v=z(a,"change",this.Ln,this));this.s()};k.setMap=function(a){this.l&&(Bc(this.l),this.l=null);a||this.s();this.o&&(Bc(this.o),this.o=null);a&&(this.l=z(a,"precompose",function(a){var b=qh(this);b.Ie=!1;b.zIndex=Infinity;a.frameState.layerStatesArray.push(b);a.frameState.layerStates[w(this)]=b},this),this.o=z(this,"change",a.render,a),this.s())};k.ad=function(a){this.set("source",a)};function vh(){this.b={};this.a=0}vh.prototype.clear=function(){this.b={};this.a=0};vh.prototype.get=function(a,b,c){a=b+":"+a+":"+(c?dd(c):"null");return a in this.b?this.b[a]:null};vh.prototype.set=function(a,b,c,d){this.b[b+":"+a+":"+(c?dd(c):"null")]=d;++this.a};var wh=new vh;var xh=Array(6);function yh(){return[1,0,0,1,0,0]}function zh(a){return Ah(a,1,0,0,1,0,0)}function Bh(a,b){var c=a[0],d=a[1],e=a[2],f=a[3],g=a[4],h=a[5],l=b[0],m=b[1],n=b[2],p=b[3],q=b[4],r=b[5];a[0]=c*l+e*m;a[1]=d*l+f*m;a[2]=c*n+e*p;a[3]=d*n+f*p;a[4]=c*q+e*r+g;a[5]=d*q+f*r+h;return a}function Ah(a,b,c,d,e,f,g){a[0]=b;a[1]=c;a[2]=d;a[3]=e;a[4]=f;a[5]=g;return a}function Ch(a,b){a[0]=b[0];a[1]=b[1];a[2]=b[2];a[3]=b[3];a[4]=b[4];a[5]=b[5];return a}
function Dh(a,b){var c=b[0],d=b[1];b[0]=a[0]*c+a[2]*d+a[4];b[1]=a[1]*c+a[3]*d+a[5];return b}function Eh(a,b){var c=Math.cos(b),d=Math.sin(b);Bh(a,Ah(xh,c,d,-d,c,0,0))}function Fh(a,b,c){return Bh(a,Ah(xh,b,0,0,c,0,0))}function Gh(a,b,c){Bh(a,Ah(xh,1,0,0,1,b,c))}function Hh(a,b,c,d,e,f,g,h){var l=Math.sin(f);f=Math.cos(f);a[0]=d*f;a[1]=e*l;a[2]=-d*l;a[3]=e*f;a[4]=g*d*f-h*d*l+b;a[5]=g*e*l+h*e*f+c;return a}
function Ih(a){var b=a[0]*a[3]-a[1]*a[2];sa(!!b,32);var c=a[0],d=a[1],e=a[2],f=a[3],g=a[4],h=a[5];a[0]=f/b;a[1]=-d/b;a[2]=-e/b;a[3]=c/b;a[4]=(e*h-f*g)/b;a[5]=-(c*h-d*g)/b;return a};function Jh(a,b){this.l=b;this.c={};this.u={}}u(Jh,Jc);function Kh(a){var b=a.viewState,c=a.coordinateToPixelTransform,d=a.pixelToCoordinateTransform;Hh(c,a.size[0]/2,a.size[1]/2,1/b.resolution,-1/b.resolution,-b.rotation,-b.center[0],-b.center[1]);Ih(Ch(d,c))}k=Jh.prototype;k.ra=function(){for(var a in this.c)Kc(this.c[a])};function Lh(){if(32<wh.a){var a=0,b,c;for(b in wh.b)c=wh.b[b],a++&3||Oc(c)||(delete wh.b[b],--wh.a)}}
k.Ba=function(a,b,c,d,e,f,g){function h(a,c){var f=w(a).toString(),g=b.layerStates[w(c)].Ie;if(!(f in b.skippedFeatureUids)||g)return d.call(e,a,g?c:null)}var l,m=b.viewState,n=m.resolution,p=m.projection,m=a;if(p.a){var p=p.D(),q=ib(p),r=a[0];if(r<p[0]||r>p[2])m=[r+q*Math.ceil((p[0]-r)/q),a[1]]}p=b.layerStatesArray;for(q=p.length-1;0<=q;--q){var v=p[q],r=v.layer;if(uh(v,n)&&f.call(g,r)&&(v=Mh(this,r),r.ka()&&(l=v.Ba(r.ka().G?m:a,b,c,h,e)),l))return l}};
k.xi=function(a,b,c,d,e){return void 0!==this.Ba(a,b,c,jf,this,d,e)};function Mh(a,b){var c=w(b).toString();if(c in a.c)return a.c[c];var d=b.Gd(a);a.c[c]=d;a.u[c]=z(d,"change",a.Al,a);return d}k.Al=function(){this.l.render()};k.Dg=oa;k.Hp=function(a,b){for(var c in this.c)if(!(b&&c in b.layerStates)){var d=c,e=this.c[d];delete this.c[d];Bc(this.u[d]);delete this.u[d];Kc(e)}};function Nh(a,b){for(var c in a.c)if(!(c in b.layerStates)){b.postRenderFunctions.push(a.Hp.bind(a));break}}
function la(a,b){return a.zIndex-b.zIndex};function Oh(a,b,c,d,e){Lc.call(this,a);this.vectorContext=b;this.frameState=c;this.context=d;this.glContext=e}u(Oh,Lc);var Ph=[0,0,0,1],Qh=[],Rh=[0,0,0,1];function Sh(a,b,c,d){b&&(a.translate(c,d),a.rotate(b),a.translate(-c,-d))};function Th(){}k=Th.prototype;k.oc=function(){};k.td=function(){};k.ac=function(){};k.te=function(){};k.ue=function(){};k.Rb=function(){};k.pc=function(){};k.qc=function(){};k.rc=function(){};k.sc=function(){};k.tc=function(){};k.Ac=function(){};k.Na=function(){};k.Wb=function(){};k.Ub=function(){};function Uh(a,b,c,d,e){this.g=a;this.v=b;this.c=c;this.O=d;this.Gb=e;this.N=this.b=this.a=this.$a=this.Z=this.I=null;this.ea=this.T=this.o=this.G=this.C=this.A=0;this.fa=!1;this.i=this.mb=0;this.na=!1;this.qa=0;this.Fa="";this.Ja=this.$b=0;this.Ha=!1;this.j=this.Va=0;this.ta=this.l=this.f=null;this.u=[];this.yb=yh()}u(Uh,Th);
function Vh(a,b,c){if(a.N){b=mf(b,0,c,2,a.O,a.u);c=a.g;var d=a.yb,e=c.globalAlpha;1!=a.o&&(c.globalAlpha=e*a.o);var f=a.mb;a.fa&&(f+=a.Gb);var g,h;g=0;for(h=b.length;g<h;g+=2){var l=b[g]-a.A,m=b[g+1]-a.C;a.na&&(l=Math.round(l),m=Math.round(m));if(f||1!=a.i){var n=l+a.A,p=m+a.C;Hh(d,n,p,a.i,a.i,f,-n,-p);c.setTransform.apply(c,d)}c.drawImage(a.N,a.T,a.ea,a.qa,a.G,l,m,a.qa,a.G)}(f||1!=a.i)&&c.setTransform(1,0,0,1,0,0);1!=a.o&&(c.globalAlpha=e)}}
function Wh(a,b,c,d){var e=0;if(a.ta&&""!==a.Fa){a.f&&Xh(a,a.f);a.l&&Yh(a,a.l);var f=a.ta,g=a.g,h=a.$a;h?(h.font!=f.font&&(h.font=g.font=f.font),h.textAlign!=f.textAlign&&(h.textAlign=g.textAlign=f.textAlign),h.textBaseline!=f.textBaseline&&(h.textBaseline=g.textBaseline=f.textBaseline)):(g.font=f.font,g.textAlign=f.textAlign,g.textBaseline=f.textBaseline,a.$a={font:f.font,textAlign:f.textAlign,textBaseline:f.textBaseline});b=mf(b,e,c,d,a.O,a.u);f=a.g;g=a.Va;for(a.Ha&&(g+=a.Gb);e<c;e+=d){var h=b[e]+
a.$b,l=b[e+1]+a.Ja;if(g||1!=a.j){var m=Hh(a.yb,h,l,a.j,a.j,g,-h,-l);f.setTransform.apply(f,m)}a.l&&f.strokeText(a.Fa,h,l);a.f&&f.fillText(a.Fa,h,l)}(g||1!=a.j)&&f.setTransform(1,0,0,1,0,0)}}function Zh(a,b,c,d,e,f){var g=a.g;a=mf(b,c,d,e,a.O,a.u);g.moveTo(a[0],a[1]);b=a.length;f&&(b-=2);for(c=2;c<b;c+=2)g.lineTo(a[c],a[c+1]);f&&g.closePath();return d}function $h(a,b,c,d,e){var f,g;f=0;for(g=d.length;f<g;++f)c=Zh(a,b,c,d[f],e,!0);return c}k=Uh.prototype;
k.ac=function(a){if(nb(this.c,a.D())){if(this.a||this.b){this.a&&Xh(this,this.a);this.b&&Yh(this,this.b);var b;b=this.O;var c=this.u,d=a.ia();b=d?mf(d,0,d.length,a.sa(),b,c):null;c=b[2]-b[0];d=b[3]-b[1];c=Math.sqrt(c*c+d*d);d=this.g;d.beginPath();d.arc(b[0],b[1],c,0,2*Math.PI);this.a&&d.fill();this.b&&d.stroke()}""!==this.Fa&&Wh(this,a.za(),2,2)}};k.td=function(a){this.Na(a.Ca(),a.Da());this.Wb(a.Y());this.Ub(a.Oa())};
k.oc=function(a){switch(a.S()){case "Point":this.sc(a);break;case "LineString":this.Rb(a);break;case "Polygon":this.tc(a);break;case "MultiPoint":this.qc(a);break;case "MultiLineString":this.pc(a);break;case "MultiPolygon":this.rc(a);break;case "GeometryCollection":this.ue(a);break;case "Circle":this.ac(a)}};k.te=function(a,b){var c=(0,b.Qa)(a);c&&nb(this.c,c.D())&&(this.td(b),this.oc(c))};k.ue=function(a){a=a.a;var b,c;b=0;for(c=a.length;b<c;++b)this.oc(a[b])};
k.sc=function(a){var b=a.ia();a=a.sa();this.N&&Vh(this,b,b.length);""!==this.Fa&&Wh(this,b,b.length,a)};k.qc=function(a){var b=a.ia();a=a.sa();this.N&&Vh(this,b,b.length);""!==this.Fa&&Wh(this,b,b.length,a)};k.Rb=function(a){if(nb(this.c,a.D())){if(this.b){Yh(this,this.b);var b=this.g,c=a.ia();b.beginPath();Zh(this,c,0,c.length,a.sa(),!1);b.stroke()}""!==this.Fa&&(a=ai(a),Wh(this,a,2,2))}};
k.pc=function(a){var b=a.D();if(nb(this.c,b)){if(this.b){Yh(this,this.b);var b=this.g,c=a.ia(),d=0,e=a.Sb(),f=a.sa();b.beginPath();var g,h;g=0;for(h=e.length;g<h;++g)d=Zh(this,c,d,e[g],f,!1);b.stroke()}""!==this.Fa&&(a=bi(a),Wh(this,a,a.length,2))}};k.tc=function(a){if(nb(this.c,a.D())){if(this.b||this.a){this.a&&Xh(this,this.a);this.b&&Yh(this,this.b);var b=this.g;b.beginPath();$h(this,a.gc(),0,a.Sb(),a.sa());this.a&&b.fill();this.b&&b.stroke()}""!==this.Fa&&(a=Tf(a),Wh(this,a,2,2))}};
k.rc=function(a){if(nb(this.c,a.D())){if(this.b||this.a){this.a&&Xh(this,this.a);this.b&&Yh(this,this.b);var b=this.g,c=ci(a),d=0,e=a.c,f=a.sa(),g,h;b.beginPath();g=0;for(h=e.length;g<h;++g)d=$h(this,c,d,e[g],f);this.a&&b.fill();this.b&&b.stroke()}""!==this.Fa&&(a=di(a),Wh(this,a,a.length,2))}};function Xh(a,b){var c=a.g,d=a.I;d?d.fillStyle!=b.fillStyle&&(d.fillStyle=c.fillStyle=b.fillStyle):(c.fillStyle=b.fillStyle,a.I={fillStyle:b.fillStyle})}
function Yh(a,b){var c=a.g,d=a.Z;d?(d.lineCap!=b.lineCap&&(d.lineCap=c.lineCap=b.lineCap),Ud&&!ja(d.lineDash,b.lineDash)&&c.setLineDash(d.lineDash=b.lineDash),d.lineJoin!=b.lineJoin&&(d.lineJoin=c.lineJoin=b.lineJoin),d.lineWidth!=b.lineWidth&&(d.lineWidth=c.lineWidth=b.lineWidth),d.miterLimit!=b.miterLimit&&(d.miterLimit=c.miterLimit=b.miterLimit),d.strokeStyle!=b.strokeStyle&&(d.strokeStyle=c.strokeStyle=b.strokeStyle)):(c.lineCap=b.lineCap,Ud&&c.setLineDash(b.lineDash),c.lineJoin=b.lineJoin,c.lineWidth=
b.lineWidth,c.miterLimit=b.miterLimit,c.strokeStyle=b.strokeStyle,a.Z={lineCap:b.lineCap,lineDash:b.lineDash,lineJoin:b.lineJoin,lineWidth:b.lineWidth,miterLimit:b.miterLimit,strokeStyle:b.strokeStyle})}
k.Na=function(a,b){if(a){var c=a.b;this.a={fillStyle:fd(c?c:Ph)}}else this.a=null;if(b){var c=b.a,d=b.i,e=b.g,f=b.f,g=b.j,h=b.c,l=b.l;this.b={lineCap:void 0!==d?d:"round",lineDash:e?e:Qh,lineDashOffset:f?f:0,lineJoin:void 0!==g?g:"round",lineWidth:this.v*(void 0!==h?h:1),miterLimit:void 0!==l?l:10,strokeStyle:fd(c?c:Rh)}}else this.b=null};
k.Wb=function(a){if(a){var b=a.Jc(),c=a.Y(1),d=a.Tc(),e=a.kc();this.A=b[0];this.C=b[1];this.G=e[1];this.N=c;this.o=a.f;this.T=d[0];this.ea=d[1];this.fa=a.o;this.mb=a.j;this.i=a.c;this.na=a.u;this.qa=e[0]}else this.N=null};
k.Ub=function(a){if(a){var b=a.Ca();b?(b=b.b,this.f={fillStyle:fd(b?b:Ph)}):this.f=null;var c=a.Da();if(c){var b=c.a,d=c.i,e=c.g,f=c.f,g=c.j,h=c.c,c=c.l;this.l={lineCap:void 0!==d?d:"round",lineDash:e?e:Qh,lineDashOffset:f?f:0,lineJoin:void 0!==g?g:"round",lineWidth:void 0!==h?h:1,miterLimit:void 0!==c?c:10,strokeStyle:fd(b?b:Rh)}}else this.l=null;var b=a.a,d=a.g,e=a.c,f=a.l,g=a.i,h=a.b,c=a.Oa(),l=a.f;a=a.j;this.ta={font:void 0!==b?b:"10px sans-serif",textAlign:void 0!==l?l:"center",textBaseline:void 0!==
a?a:"middle"};this.Fa=void 0!==c?c:"";this.$b=void 0!==d?this.v*d:0;this.Ja=void 0!==e?this.v*e:0;this.Ha=void 0!==f?f:!1;this.Va=void 0!==g?g:0;this.j=this.v*(void 0!==h?h:1)}else this.Fa=""};function ei(a,b){Jh.call(this,0,b);this.g=hd();this.b=this.g.canvas;this.b.style.width="100%";this.b.style.height="100%";this.b.style.display="block";this.b.className="ol-unselectable";a.insertBefore(this.b,a.childNodes[0]||null);this.a=!0;this.i=yh()}u(ei,Jh);
function fi(a,b,c){var d=a.l,e=a.g;if(Oc(d,b)){var f=c.extent,g=c.pixelRatio,h=c.viewState.rotation,l=c.viewState,m=c.pixelRatio/l.resolution;a=Hh(a.i,a.b.width/2,a.b.height/2,m,-m,-l.rotation,-l.center[0],-l.center[1]);d.b(new Oh(b,new Uh(e,g,f,a,h),c,e,null))}}ei.prototype.S=function(){return"canvas"};
ei.prototype.Dg=function(a){if(a){var b=this.g,c=a.pixelRatio,d=Math.round(a.size[0]*c),e=Math.round(a.size[1]*c);this.b.width!=d||this.b.height!=e?(this.b.width=d,this.b.height=e):b.clearRect(0,0,d,e);c=a.viewState.rotation;Kh(a);fi(this,"precompose",a);var f=a.layerStatesArray;ka(f);c&&(b.save(),Sh(b,c,d/2,e/2));var d=a.viewState.resolution,g,h,l,e=0;for(g=f.length;e<g;++e)l=f[e],h=l.layer,h=Mh(this,h),uh(l,d)&&"ready"==l.uj&&h.ud(a,l)&&h.O(a,l,b);c&&b.restore();fi(this,"postcompose",a);this.a||
(this.b.style.display="",this.a=!0);Nh(this,a);a.postRenderFunctions.push(Lh)}else this.a&&(this.b.style.display="none",this.a=!1)};ei.prototype.wi=function(a,b,c,d,e,f){var g,h=b.viewState.resolution,l=b.layerStatesArray,m=l.length;a=Dh(b.pixelToCoordinateTransform,a.slice());for(--m;0<=m;--m){g=l[m];var n=g.layer;if(uh(g,h)&&e.call(f,n)&&(g=Mh(this,n).v(a,b,c,d)))return g}};var gi=["Polygon","Circle","LineString","Image","Text"];function hi(){};function ii(a){this.b=a};function ji(a){this.b=a}u(ji,ii);ji.prototype.S=function(){return 35632};function ki(a){this.b=a}u(ki,ii);ki.prototype.S=function(){return 35633};function li(){this.b="precision mediump float;varying vec2 a;varying vec2 b;varying float c;varying float d;uniform float m;uniform vec4 n;uniform vec4 o;uniform vec2 p;void main(void){vec2 windowCenter=vec2((a.x+1.0)/2.0*p.x*d,(a.y+1.0)/2.0*p.y*d);vec2 windowOffset=vec2((b.x+1.0)/2.0*p.x*d,(b.y+1.0)/2.0*p.y*d);float radius=length(windowCenter-windowOffset);float dist=length(windowCenter-gl_FragCoord.xy);if(dist>radius+c){if(o.a==0.0){gl_FragColor=n;}else{gl_FragColor=o;}gl_FragColor.a=gl_FragColor.a-(dist-(radius+c));}else if(n.a==0.0){gl_FragColor=o;if(dist<radius-c){gl_FragColor.a=gl_FragColor.a-(radius-c-dist);}} else{gl_FragColor=n;float strokeDist=radius-c;float antialias=2.0*d;if(dist>strokeDist){gl_FragColor=o;}else if(dist>=strokeDist-antialias){float step=smoothstep(strokeDist-antialias,strokeDist,dist);gl_FragColor=mix(n,o,step);}} gl_FragColor.a=gl_FragColor.a*m;if(gl_FragColor.a<=0.0){discard;}}"}
u(li,ji);var mi=new li;
function ni(){this.b="varying vec2 a;varying vec2 b;varying float c;varying float d;attribute vec2 e;attribute float f;attribute float g;uniform mat4 h;uniform mat4 i;uniform mat4 j;uniform float k;uniform float l;void main(void){mat4 offsetMatrix=i*j;a=vec4(h*vec4(e,0.0,1.0)).xy;d=l;float lineWidth=k*l;c=lineWidth/2.0;if(lineWidth==0.0){lineWidth=2.0*l;}vec2 offset;float radius=g+3.0*l;if(f==0.0){offset=vec2(-1.0,1.0);}else if(f==1.0){offset=vec2(-1.0,-1.0);}else if(f==2.0){offset=vec2(1.0,-1.0);}else{offset=vec2(1.0,1.0);}gl_Position=h*vec4(e+offset*radius,0.0,1.0)+offsetMatrix*vec4(offset*lineWidth,0.0,0.0);b=vec4(h*vec4(e.x+g,e.y,0.0,1.0)).xy;if(distance(a,b)>20000.0){gl_Position=vec4(a,0.0,1.0);}}"}
u(ni,ki);var oi=new ni;function pi(a,b){this.G=a.getUniformLocation(b,"n");this.qa=a.getUniformLocation(b,"k");this.c=a.getUniformLocation(b,"j");this.i=a.getUniformLocation(b,"i");this.a=a.getUniformLocation(b,"m");this.ta=a.getUniformLocation(b,"l");this.g=a.getUniformLocation(b,"h");this.I=a.getUniformLocation(b,"p");this.Z=a.getUniformLocation(b,"o");this.j=a.getAttribLocation(b,"f");this.b=a.getAttribLocation(b,"e");this.O=a.getAttribLocation(b,"g")};function qi(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function ri(a,b){a[0]=b[0];a[1]=b[1];a[4]=b[2];a[5]=b[3];a[12]=b[4];a[13]=b[5];return a};function si(a,b){this.origin=kb(b);this.Gb=yh();this.Va=yh();this.yb=yh();this.Ja=qi();this.b=[];this.o=null;this.g=[];this.f=[];this.a=[];this.u=null;this.j=void 0}u(si,Th);
si.prototype.i=function(a,b,c,d,e,f,g,h,l,m,n){var p=a.b,q,r,v,x,y,A,B,aa;this.j&&(q=p.isEnabled(p.STENCIL_TEST),r=p.getParameter(p.STENCIL_FUNC),v=p.getParameter(p.STENCIL_VALUE_MASK),x=p.getParameter(p.STENCIL_REF),y=p.getParameter(p.STENCIL_WRITEMASK),A=p.getParameter(p.STENCIL_FAIL),B=p.getParameter(p.STENCIL_PASS_DEPTH_PASS),aa=p.getParameter(p.STENCIL_PASS_DEPTH_FAIL),p.enable(p.STENCIL_TEST),p.clear(p.STENCIL_BUFFER_BIT),p.stencilMask(255),p.stencilFunc(p.ALWAYS,1,255),p.stencilOp(p.KEEP,p.KEEP,
p.REPLACE),this.j.i(a,b,c,d,e,f,g,h,l,m,n),p.stencilMask(0),p.stencilFunc(p.NOTEQUAL,1,255));ti(a,34962,this.u);ti(a,34963,this.o);f=this.qf(p,a,e,f);var Ra=zh(this.Gb);Fh(Ra,2/(c*e[0]),2/(c*e[1]));Eh(Ra,-d);Gh(Ra,-(b[0]-this.origin[0]),-(b[1]-this.origin[1]));b=zh(this.yb);Fh(b,2/e[0],2/e[1]);e=zh(this.Va);d&&Eh(e,-d);p.uniformMatrix4fv(f.g,!1,ri(this.Ja,Ra));p.uniformMatrix4fv(f.i,!1,ri(this.Ja,b));p.uniformMatrix4fv(f.c,!1,ri(this.Ja,e));p.uniform1f(f.a,g);var ra;l?(m?a=this.ve(p,a,h,l,n):(p.clear(p.COLOR_BUFFER_BIT|
p.DEPTH_BUFFER_BIT),this.Pd(p,a,h,!0),a=(a=l(null))?a:void 0),ra=a):this.Pd(p,a,h,!1);this.rf(p,f);this.j&&(q||p.disable(p.STENCIL_TEST),p.clear(p.STENCIL_BUFFER_BIT),p.stencilFunc(r,x,v),p.stencilMask(y),p.stencilOp(A,aa,B));return ra};function ui(a,b,c,d){a.drawElements(4,d-c,b.f?5125:5123,c*(b.f?4:2))};var vi=[0,0,0,1],wi=[],xi=[0,0,0,1];function yi(a,b,c,d,e,f){a=(c-a)*(f-b)-(e-a)*(d-b);return a<=zi&&a>=-zi?void 0:0<a}var zi=Number.EPSILON||2.220446049250313E-16;function Ai(a){this.b=void 0!==a?a:[];this.a=Bi}var Bi=35044;function Ci(a,b){si.call(this,0,b);this.v=null;this.l=[];this.O=[];this.A=0;this.c={fillColor:null,strokeColor:null,lineDash:null,lineDashOffset:void 0,lineWidth:void 0,s:!1}}u(Ci,si);k=Ci.prototype;
k.ac=function(a,b){var c=a.Yd(),d=a.sa();if(c){this.g.push(this.b.length);this.f.push(b);this.c.s&&(this.O.push(this.b.length),this.c.s=!1);this.A=c;var c=a.ia(),c=nf(c,2,d,-this.origin[0],-this.origin[1]),e=this.a.length,f=this.b.length,g=e/4,h;for(h=0;2>h;h+=d)this.a[e++]=c[h],this.a[e++]=c[h+1],this.a[e++]=0,this.a[e++]=this.A,this.a[e++]=c[h],this.a[e++]=c[h+1],this.a[e++]=1,this.a[e++]=this.A,this.a[e++]=c[h],this.a[e++]=c[h+1],this.a[e++]=2,this.a[e++]=this.A,this.a[e++]=c[h],this.a[e++]=c[h+
1],this.a[e++]=3,this.a[e++]=this.A,this.b[f++]=g,this.b[f++]=g+1,this.b[f++]=g+2,this.b[f++]=g+2,this.b[f++]=g+3,this.b[f++]=g,g+=4}else this.c.s&&(this.l.pop(),this.l.length&&(d=this.l[this.l.length-1],this.c.fillColor=d[0],this.c.strokeColor=d[1],this.c.lineWidth=d[2],this.c.s=!1))};k.Bb=function(){this.u=new Ai(this.a);this.o=new Ai(this.b);this.g.push(this.b.length);!this.O.length&&0<this.l.length&&(this.l=[]);this.b=this.a=null};
k.Cb=function(a){var b=this.u,c=this.o;return function(){Di(a,b);Di(a,c)}};k.qf=function(a,b,c,d){var e=Ei(b,mi,oi),f;this.v?f=this.v:this.v=f=new pi(a,e);b.Vc(e);a.enableVertexAttribArray(f.b);a.vertexAttribPointer(f.b,2,5126,!1,16,0);a.enableVertexAttribArray(f.j);a.vertexAttribPointer(f.j,1,5126,!1,16,8);a.enableVertexAttribArray(f.O);a.vertexAttribPointer(f.O,1,5126,!1,16,12);a.uniform2fv(f.I,c);a.uniform1f(f.ta,d);return f};
k.rf=function(a,b){a.disableVertexAttribArray(b.b);a.disableVertexAttribArray(b.j);a.disableVertexAttribArray(b.O)};
k.Pd=function(a,b,c){if(tb(c)){var d,e,f;e=this.g[this.g.length-1];for(c=this.O.length-1;0<=c;--c)d=this.O[c],f=this.l[c],a.uniform4fv(this.v.G,f[0]),Fi(this,a,f[1],f[2]),ui(a,b,d,e),e=d}else{var g,h,l,m;l=this.g.length-2;f=e=this.g[l+1];for(d=this.O.length-1;0<=d;--d){g=this.l[d];a.uniform4fv(this.v.G,g[0]);Fi(this,a,g[1],g[2]);for(g=this.O[d];0<=l&&this.g[l]>=g;)m=this.g[l],h=this.f[l],h=w(h).toString(),c[h]&&(e!==f&&ui(a,b,e,f),f=m),l--,e=m;e!==f&&ui(a,b,e,f);e=f=g}}};
k.ve=function(a,b,c,d,e){var f,g,h,l,m,n,p;p=this.g.length-2;h=this.g[p+1];for(f=this.O.length-1;0<=f;--f)for(g=this.l[f],a.uniform4fv(this.v.G,g[0]),Fi(this,a,g[1],g[2]),l=this.O[f];0<=p&&this.g[p]>=l;){g=this.g[p];m=this.f[p];n=w(m).toString();if(void 0===c[n]&&m.U()&&(void 0===e||nb(e,m.U().D()))&&(a.clear(a.COLOR_BUFFER_BIT|a.DEPTH_BUFFER_BIT),ui(a,b,g,h),h=d(m)))return h;p--;h=g}};function Fi(a,b,c,d){b.uniform4fv(a.v.Z,c);b.uniform1f(a.v.qa,d)}
k.Na=function(a,b){var c,d;b?(c=b.g,this.c.lineDash=c?c:wi,c=b.f,this.c.lineDashOffset=c?c:0,c=b.a,c instanceof CanvasGradient||c instanceof CanvasPattern?c=xi:c=bd(c).map(function(a,b){return 3!=b?a/255:a})||xi,d=b.c,d=void 0!==d?d:1):(c=[0,0,0,0],d=0);var e=a?a.b:[0,0,0,0];e instanceof CanvasGradient||e instanceof CanvasPattern?e=vi:e=bd(e).map(function(a,b){return 3!=b?a/255:a})||vi;this.c.strokeColor&&ja(this.c.strokeColor,c)&&this.c.fillColor&&ja(this.c.fillColor,e)&&this.c.lineWidth===d||(this.c.s=
!0,this.c.fillColor=e,this.c.strokeColor=c,this.c.lineWidth=d,this.l.push([e,c,d]))};function Gi(){this.b="precision mediump float;varying vec2 a;varying float b;uniform float k;uniform sampler2D l;void main(void){vec4 texColor=texture2D(l,a);gl_FragColor.rgb=texColor.rgb;float alpha=texColor.a*b*k;if(alpha==0.0){discard;}gl_FragColor.a=alpha;}"}u(Gi,ji);var Hi=new Gi;
function Ii(){this.b="varying vec2 a;varying float b;attribute vec2 c;attribute vec2 d;attribute vec2 e;attribute float f;attribute float g;uniform mat4 h;uniform mat4 i;uniform mat4 j;void main(void){mat4 offsetMatrix=i;if(g==1.0){offsetMatrix=i*j;}vec4 offsets=offsetMatrix*vec4(e,0.0,0.0);gl_Position=h*vec4(c,0.0,1.0)+offsets;a=d;b=f;}"}u(Ii,ki);var Ji=new Ii;
function Ki(a,b){this.c=a.getUniformLocation(b,"j");this.i=a.getUniformLocation(b,"i");this.a=a.getUniformLocation(b,"k");this.g=a.getUniformLocation(b,"h");this.u=a.getAttribLocation(b,"e");this.v=a.getAttribLocation(b,"f");this.b=a.getAttribLocation(b,"c");this.A=a.getAttribLocation(b,"g");this.C=a.getAttribLocation(b,"d")};function Li(a,b){this.j=a;this.b=b;this.a={};this.c={};this.g={};this.o=this.u=this.i=this.l=null;(this.f=fa(da,"OES_element_index_uint"))&&b.getExtension("OES_element_index_uint");z(this.j,"webglcontextlost",this.No,this);z(this.j,"webglcontextrestored",this.Oo,this)}u(Li,Jc);
function ti(a,b,c){var d=a.b,e=c.b,f=String(w(c));if(f in a.a)d.bindBuffer(b,a.a[f].buffer);else{var g=d.createBuffer();d.bindBuffer(b,g);var h;34962==b?h=new Float32Array(e):34963==b&&(h=a.f?new Uint32Array(e):new Uint16Array(e));d.bufferData(b,h,c.a);a.a[f]={nc:c,buffer:g}}}function Di(a,b){var c=a.b,d=String(w(b)),e=a.a[d];c.isContextLost()||c.deleteBuffer(e.buffer);delete a.a[d]}k=Li.prototype;
k.ra=function(){Ic(this.j);var a=this.b;if(!a.isContextLost()){for(var b in this.a)a.deleteBuffer(this.a[b].buffer);for(b in this.g)a.deleteProgram(this.g[b]);for(b in this.c)a.deleteShader(this.c[b]);a.deleteFramebuffer(this.i);a.deleteRenderbuffer(this.o);a.deleteTexture(this.u)}};k.Mo=function(){return this.b};
function Mi(a){if(!a.i){var b=a.b,c=b.createFramebuffer();b.bindFramebuffer(b.FRAMEBUFFER,c);var d=Ni(b,1,1),e=b.createRenderbuffer();b.bindRenderbuffer(b.RENDERBUFFER,e);b.renderbufferStorage(b.RENDERBUFFER,b.DEPTH_COMPONENT16,1,1);b.framebufferTexture2D(b.FRAMEBUFFER,b.COLOR_ATTACHMENT0,b.TEXTURE_2D,d,0);b.framebufferRenderbuffer(b.FRAMEBUFFER,b.DEPTH_ATTACHMENT,b.RENDERBUFFER,e);b.bindTexture(b.TEXTURE_2D,null);b.bindRenderbuffer(b.RENDERBUFFER,null);b.bindFramebuffer(b.FRAMEBUFFER,null);a.i=c;
a.u=d;a.o=e}return a.i}function Oi(a,b){var c=String(w(b));if(c in a.c)return a.c[c];var d=a.b,e=d.createShader(b.S());d.shaderSource(e,b.b);d.compileShader(e);return a.c[c]=e}function Ei(a,b,c){var d=w(b)+"/"+w(c);if(d in a.g)return a.g[d];var e=a.b,f=e.createProgram();e.attachShader(f,Oi(a,b));e.attachShader(f,Oi(a,c));e.linkProgram(f);return a.g[d]=f}k.No=function(){rb(this.a);rb(this.c);rb(this.g);this.o=this.u=this.i=this.l=null};k.Oo=function(){};
k.Vc=function(a){if(a==this.l)return!1;this.b.useProgram(a);this.l=a;return!0};function Pi(a,b,c){var d=a.createTexture();a.bindTexture(a.TEXTURE_2D,d);a.texParameteri(a.TEXTURE_2D,a.TEXTURE_MAG_FILTER,a.LINEAR);a.texParameteri(a.TEXTURE_2D,a.TEXTURE_MIN_FILTER,a.LINEAR);void 0!==b&&a.texParameteri(3553,10242,b);void 0!==c&&a.texParameteri(3553,10243,c);return d}function Ni(a,b,c){var d=Pi(a,void 0,void 0);a.texImage2D(a.TEXTURE_2D,0,a.RGBA,b,c,0,a.RGBA,a.UNSIGNED_BYTE,null);return d}
function Qi(a,b){var c=Pi(a,33071,33071);a.texImage2D(a.TEXTURE_2D,0,a.RGBA,a.RGBA,a.UNSIGNED_BYTE,b);return c};function Ri(a,b){si.call(this,0,b);this.G=this.C=void 0;this.A=[];this.v=[];this.ta=void 0;this.l=[];this.c=[];this.Z=this.I=void 0;this.qa=null;this.na=this.mb=this.fa=this.ea=this.T=this.$a=void 0;this.Ha=[];this.O=[];this.$b=void 0}u(Ri,si);k=Ri.prototype;k.Cb=function(a){var b=this.u,c=this.o,d=this.Ha,e=this.O,f=a.b;return function(){if(!f.isContextLost()){var g,h;g=0;for(h=d.length;g<h;++g)f.deleteTexture(d[g]);g=0;for(h=e.length;g<h;++g)f.deleteTexture(e[g])}Di(a,b);Di(a,c)}};
function Si(a,b,c,d){var e=a.C,f=a.G,g=a.ta,h=a.I,l=a.Z,m=a.$a,n=a.T,p=a.ea,q=a.fa?1:0,r=-a.mb,v=a.na,x=a.$b,y=Math.cos(r),r=Math.sin(r),A=a.b.length,B=a.a.length,aa,Ra,ra,Ka,C,Na;for(aa=0;aa<c;aa+=d)C=b[aa]-a.origin[0],Na=b[aa+1]-a.origin[1],Ra=B/8,ra=-v*e,Ka=-v*(g-f),a.a[B++]=C,a.a[B++]=Na,a.a[B++]=ra*y-Ka*r,a.a[B++]=ra*r+Ka*y,a.a[B++]=n/l,a.a[B++]=(p+g)/h,a.a[B++]=m,a.a[B++]=q,ra=v*(x-e),Ka=-v*(g-f),a.a[B++]=C,a.a[B++]=Na,a.a[B++]=ra*y-Ka*r,a.a[B++]=ra*r+Ka*y,a.a[B++]=(n+x)/l,a.a[B++]=(p+g)/h,
a.a[B++]=m,a.a[B++]=q,ra=v*(x-e),Ka=v*f,a.a[B++]=C,a.a[B++]=Na,a.a[B++]=ra*y-Ka*r,a.a[B++]=ra*r+Ka*y,a.a[B++]=(n+x)/l,a.a[B++]=p/h,a.a[B++]=m,a.a[B++]=q,ra=-v*e,Ka=v*f,a.a[B++]=C,a.a[B++]=Na,a.a[B++]=ra*y-Ka*r,a.a[B++]=ra*r+Ka*y,a.a[B++]=n/l,a.a[B++]=p/h,a.a[B++]=m,a.a[B++]=q,a.b[A++]=Ra,a.b[A++]=Ra+1,a.b[A++]=Ra+2,a.b[A++]=Ra,a.b[A++]=Ra+2,a.b[A++]=Ra+3}k.qc=function(a,b){this.g.push(this.b.length);this.f.push(b);var c=a.ia();Si(this,c,c.length,a.sa())};
k.sc=function(a,b){this.g.push(this.b.length);this.f.push(b);var c=a.ia();Si(this,c,c.length,a.sa())};k.Bb=function(a){a=a.b;this.A.push(this.b.length);this.v.push(this.b.length);this.u=new Ai(this.a);this.o=new Ai(this.b);var b={};Ti(this.Ha,this.l,b,a);Ti(this.O,this.c,b,a);this.ta=this.G=this.C=void 0;this.c=this.l=null;this.Z=this.I=void 0;this.b=null;this.na=this.mb=this.fa=this.ea=this.T=this.$a=void 0;this.a=null;this.$b=void 0};
function Ti(a,b,c,d){var e,f,g,h=b.length;for(g=0;g<h;++g)e=b[g],f=w(e).toString(),f in c?e=c[f]:(e=Qi(d,e),c[f]=e),a[g]=e}
k.qf=function(a,b){var c=Ei(b,Hi,Ji),d;this.qa?d=this.qa:this.qa=d=new Ki(a,c);b.Vc(c);a.enableVertexAttribArray(d.b);a.vertexAttribPointer(d.b,2,5126,!1,32,0);a.enableVertexAttribArray(d.u);a.vertexAttribPointer(d.u,2,5126,!1,32,8);a.enableVertexAttribArray(d.C);a.vertexAttribPointer(d.C,2,5126,!1,32,16);a.enableVertexAttribArray(d.v);a.vertexAttribPointer(d.v,1,5126,!1,32,24);a.enableVertexAttribArray(d.A);a.vertexAttribPointer(d.A,1,5126,!1,32,28);return d};
k.rf=function(a,b){a.disableVertexAttribArray(b.b);a.disableVertexAttribArray(b.u);a.disableVertexAttribArray(b.C);a.disableVertexAttribArray(b.v);a.disableVertexAttribArray(b.A)};
k.Pd=function(a,b,c,d){var e=d?this.O:this.Ha;d=d?this.v:this.A;if(tb(c)){var f,g;c=0;f=e.length;for(g=0;c<f;++c){a.bindTexture(3553,e[c]);var h=d[c];ui(a,b,g,h);g=h}}else for(g=f=0,h=e.length;g<h;++g){a.bindTexture(3553,e[g]);for(var l=0<g?d[g-1]:0,m=d[g],n=l;f<this.g.length&&this.g[f]<=m;){var p=w(this.f[f]).toString();void 0!==c[p]?(n!==l&&ui(a,b,n,l),l=n=f===this.g.length-1?m:this.g[f+1]):l=f===this.g.length-1?m:this.g[f+1];f++}n!==l&&ui(a,b,n,l)}};
k.ve=function(a,b,c,d,e){var f,g,h,l,m,n,p=this.g.length-1;for(f=this.O.length-1;0<=f;--f)for(a.bindTexture(3553,this.O[f]),g=0<f?this.v[f-1]:0,l=this.v[f];0<=p&&this.g[p]>=g;){h=this.g[p];m=this.f[p];n=w(m).toString();if(void 0===c[n]&&m.U()&&(void 0===e||nb(e,m.U().D()))&&(a.clear(a.COLOR_BUFFER_BIT|a.DEPTH_BUFFER_BIT),ui(a,b,h,l),l=d(m)))return l;l=h;p--}};
k.Wb=function(a){var b=a.Jc(),c=a.Y(1),d=a.ye(),e=a.kg(1),f=a.f,g=a.Tc(),h=a.o,l=a.j,m=a.kc();a=a.c;var n;this.l.length?(n=this.l[this.l.length-1],w(n)!=w(c)&&(this.A.push(this.b.length),this.l.push(c))):this.l.push(c);this.c.length?(n=this.c[this.c.length-1],w(n)!=w(e)&&(this.v.push(this.b.length),this.c.push(e))):this.c.push(e);this.C=b[0];this.G=b[1];this.ta=m[1];this.I=d[1];this.Z=d[0];this.$a=f;this.T=g[0];this.ea=g[1];this.mb=l;this.fa=h;this.na=a;this.$b=m[0]};function Ui(a,b,c){var d=b-c;return a[0]===a[d]&&a[1]===a[d+1]&&3<(b-0)/c?!!sf(a,0,b,c):!1};function Vi(){this.b="precision mediump float;varying float a;varying vec2 b;varying float c;uniform float m;uniform vec4 n;uniform vec2 o;uniform float p;void main(void){if(a>0.0){vec2 windowCoords=vec2((b.x+1.0)/2.0*o.x*p,(b.y+1.0)/2.0*o.y*p);if(length(windowCoords-gl_FragCoord.xy)>c*p){discard;}} gl_FragColor=n;float alpha=n.a*m;if(alpha==0.0){discard;}gl_FragColor.a=alpha;}"}u(Vi,ji);var Wi=new Vi;
function Xi(){this.b="varying float a;varying vec2 b;varying float c;attribute vec2 d;attribute vec2 e;attribute vec2 f;attribute float g;uniform mat4 h;uniform mat4 i;uniform mat4 j;uniform float k;uniform float l;bool nearlyEquals(in float value,in float ref){float epsilon=0.000000000001;return value>=ref-epsilon&&value<=ref+epsilon;}void alongNormal(out vec2 offset,in vec2 nextP,in float turnDir,in float direction){vec2 dirVect=nextP-e;vec2 normal=normalize(vec2(-turnDir*dirVect.y,turnDir*dirVect.x));offset=k/2.0*normal*direction;}void miterUp(out vec2 offset,out float round,in bool isRound,in float direction){float halfWidth=k/2.0;vec2 tangent=normalize(normalize(f-e)+normalize(e-d));vec2 normal=vec2(-tangent.y,tangent.x);vec2 dirVect=f-e;vec2 tmpNormal=normalize(vec2(-dirVect.y,dirVect.x));float miterLength=abs(halfWidth/dot(normal,tmpNormal));offset=normal*direction*miterLength;round=0.0;if(isRound){round=1.0;}else if(miterLength>l+k){offset=halfWidth*tmpNormal*direction;}} bool miterDown(out vec2 offset,in vec4 projPos,in mat4 offsetMatrix,in float direction){bool degenerate=false;vec2 tangent=normalize(normalize(f-e)+normalize(e-d));vec2 normal=vec2(-tangent.y,tangent.x);vec2 dirVect=d-e;vec2 tmpNormal=normalize(vec2(-dirVect.y,dirVect.x));vec2 longOffset,shortOffset,longVertex;vec4 shortProjVertex;float halfWidth=k/2.0;if(length(f-e)>length(d-e)){longOffset=tmpNormal*direction*halfWidth;shortOffset=normalize(vec2(dirVect.y,-dirVect.x))*direction*halfWidth;longVertex=f;shortProjVertex=h*vec4(d,0.0,1.0);}else{shortOffset=tmpNormal*direction*halfWidth;longOffset=normalize(vec2(dirVect.y,-dirVect.x))*direction*halfWidth;longVertex=d;shortProjVertex=h*vec4(f,0.0,1.0);}vec4 p1=h*vec4(longVertex,0.0,1.0)+offsetMatrix*vec4(longOffset,0.0,0.0);vec4 p2=projPos+offsetMatrix*vec4(longOffset,0.0,0.0);vec4 p3=shortProjVertex+offsetMatrix*vec4(-shortOffset,0.0,0.0);vec4 p4=shortProjVertex+offsetMatrix*vec4(shortOffset,0.0,0.0);float denom=(p4.y-p3.y)*(p2.x-p1.x)-(p4.x-p3.x)*(p2.y-p1.y);float firstU=((p4.x-p3.x)*(p1.y-p3.y)-(p4.y-p3.y)*(p1.x-p3.x))/denom;float secondU=((p2.x-p1.x)*(p1.y-p3.y)-(p2.y-p1.y)*(p1.x-p3.x))/denom;float epsilon=0.000000000001;if(firstU>epsilon&&firstU<1.0-epsilon&&secondU>epsilon&&secondU<1.0-epsilon){shortProjVertex.x=p1.x+firstU*(p2.x-p1.x);shortProjVertex.y=p1.y+firstU*(p2.y-p1.y);offset=shortProjVertex.xy;degenerate=true;}else{float miterLength=abs(halfWidth/dot(normal,tmpNormal));offset=normal*direction*miterLength;}return degenerate;}void squareCap(out vec2 offset,out float round,in bool isRound,in vec2 nextP,in float turnDir,in float direction){round=0.0;vec2 dirVect=e-nextP;vec2 firstNormal=normalize(dirVect);vec2 secondNormal=vec2(turnDir*firstNormal.y*direction,-turnDir*firstNormal.x*direction);vec2 hypotenuse=normalize(firstNormal-secondNormal);vec2 normal=vec2(turnDir*hypotenuse.y*direction,-turnDir*hypotenuse.x*direction);float length=sqrt(c*c*2.0);offset=normal*length;if(isRound){round=1.0;}} void main(void){bool degenerate=false;float direction=float(sign(g));mat4 offsetMatrix=i*j;vec2 offset;vec4 projPos=h*vec4(e,0.0,1.0);bool round=nearlyEquals(mod(g,2.0),0.0);a=0.0;c=k/2.0;b=projPos.xy;if(nearlyEquals(mod(g,3.0),0.0)||nearlyEquals(mod(g,17.0),0.0)){alongNormal(offset,f,1.0,direction);}else if(nearlyEquals(mod(g,5.0),0.0)||nearlyEquals(mod(g,13.0),0.0)){alongNormal(offset,d,-1.0,direction);}else if(nearlyEquals(mod(g,23.0),0.0)){miterUp(offset,a,round,direction);}else if(nearlyEquals(mod(g,19.0),0.0)){degenerate=miterDown(offset,projPos,offsetMatrix,direction);}else if(nearlyEquals(mod(g,7.0),0.0)){squareCap(offset,a,round,f,1.0,direction);}else if(nearlyEquals(mod(g,11.0),0.0)){squareCap(offset,a,round,d,-1.0,direction);}if(!degenerate){vec4 offsets=offsetMatrix*vec4(offset,0.0,0.0);gl_Position=projPos+offsets;}else{gl_Position=vec4(offset,0.0,1.0);}}"}
u(Xi,ki);var Yi=new Xi;function Zi(a,b){this.G=a.getUniformLocation(b,"n");this.qa=a.getUniformLocation(b,"k");this.Z=a.getUniformLocation(b,"l");this.c=a.getUniformLocation(b,"j");this.i=a.getUniformLocation(b,"i");this.a=a.getUniformLocation(b,"m");this.ta=a.getUniformLocation(b,"p");this.g=a.getUniformLocation(b,"h");this.I=a.getUniformLocation(b,"o");this.f=a.getAttribLocation(b,"g");this.l=a.getAttribLocation(b,"d");this.o=a.getAttribLocation(b,"f");this.b=a.getAttribLocation(b,"e")};function $i(a,b){si.call(this,0,b);this.v=null;this.O=[];this.l=[];this.c={strokeColor:null,lineCap:void 0,lineDash:null,lineDashOffset:void 0,lineJoin:void 0,lineWidth:void 0,miterLimit:void 0,s:!1}}u($i,si);
function aj(a,b,c,d){var e,f=a.a.length,g=a.b.length,h="bevel"===a.c.lineJoin?0:"miter"===a.c.lineJoin?1:2,l="butt"===a.c.lineCap?0:"square"===a.c.lineCap?1:2,m=Ui(b,c,d),n,p,q,r=g,v=1,x,y,A;for(e=0;e<c;e+=d){q=f/7;x=y;y=A||[b[e],b[e+1]];if(e)if(e===c-d){m?A=n:(x=x||[0,0],f=bj(a,x,y,[0,0],v*cj*(l||1),f),f=bj(a,x,y,[0,0],-v*cj*(l||1),f),a.b[g++]=q,a.b[g++]=r-1,a.b[g++]=r,a.b[g++]=r,a.b[g++]=q+1,a.b[g++]=q,l&&(f=bj(a,x,y,[0,0],v*dj*l,f),f=bj(a,x,y,[0,0],-v*dj*l,f),a.b[g++]=q+2,a.b[g++]=q,a.b[g++]=q+
1,a.b[g++]=q+1,a.b[g++]=q+3,a.b[g++]=q+2));break}else A=[b[e+d],b[e+d+1]];else{A=[b[e+d],b[e+d+1]];if(c-0===2*d&&ja(y,A))break;if(m)x=[b[c-2*d],b[c-2*d+1]],n=A;else{l&&(f=bj(a,[0,0],y,A,v*ej*l,f),f=bj(a,[0,0],y,A,-v*ej*l,f),a.b[g++]=q+2,a.b[g++]=q,a.b[g++]=q+1,a.b[g++]=q+1,a.b[g++]=q+3,a.b[g++]=q+2);f=bj(a,[0,0],y,A,v*fj*(l||1),f);f=bj(a,[0,0],y,A,-v*fj*(l||1),f);r=f/7-1;continue}}p=yi(x[0],x[1],y[0],y[1],A[0],A[1])?-1:1;f=bj(a,x,y,A,p*gj*(h||1),f);f=bj(a,x,y,A,p*hj*(h||1),f);f=bj(a,x,y,A,-p*ij*(h||
1),f);0<e&&(a.b[g++]=q,a.b[g++]=r-1,a.b[g++]=r,a.b[g++]=q+2,a.b[g++]=q,a.b[g++]=0<v*p?r:r-1);a.b[g++]=q;a.b[g++]=q+2;a.b[g++]=q+1;r=q+2;v=p;h&&(f=bj(a,x,y,A,p*jj*h,f),a.b[g++]=q+1,a.b[g++]=q+3,a.b[g++]=q)}m&&(q=q||f/7,p=Pf([x[0],x[1],y[0],y[1],A[0],A[1]],0,6,2)?1:-1,f=bj(a,x,y,A,p*gj*(h||1),f),bj(a,x,y,A,-p*ij*(h||1),f),a.b[g++]=q,a.b[g++]=r-1,a.b[g++]=r,a.b[g++]=q+1,a.b[g++]=q,a.b[g++]=0<v*p?r:r-1)}
function bj(a,b,c,d,e,f){a.a[f++]=b[0];a.a[f++]=b[1];a.a[f++]=c[0];a.a[f++]=c[1];a.a[f++]=d[0];a.a[f++]=d[1];a.a[f++]=e;return f}function kj(a,b,c){b-=0;return b<2*c?!1:b===2*c?!ja([a[0],a[1]],[a[0+c],a[c+1]]):!0}k=$i.prototype;k.Rb=function(a,b){var c=a.ia(),d=a.sa();kj(c,c.length,d)&&(c=nf(c,c.length,d,-this.origin[0],-this.origin[1]),this.c.s&&(this.l.push(this.b.length),this.c.s=!1),this.g.push(this.b.length),this.f.push(b),aj(this,c,c.length,d))};
k.pc=function(a,b){var c=this.b.length,d=a.Nc(),e,f;e=0;for(f=d.length;e<f;++e){var g=d[e].ia(),h=d[e].sa();kj(g,g.length,h)&&(g=nf(g,g.length,h,-this.origin[0],-this.origin[1]),aj(this,g,g.length,h))}this.b.length>c&&(this.g.push(c),this.f.push(b),this.c.s&&(this.l.push(c),this.c.s=!1))};
function lj(a,b,c,d){Ui(b,b.length,d)||(b.push(b[0]),b.push(b[1]));aj(a,b,b.length,d);if(c.length){var e;b=0;for(e=c.length;b<e;++b)Ui(c[b],c[b].length,d)||(c[b].push(c[b][0]),c[b].push(c[b][1])),aj(a,c[b],c[b].length,d)}}function mj(a,b,c){c=void 0===c?a.b.length:c;a.g.push(c);a.f.push(b);a.c.s&&(a.l.push(c),a.c.s=!1)}k.Bb=function(){this.u=new Ai(this.a);this.o=new Ai(this.b);this.g.push(this.b.length);!this.l.length&&0<this.O.length&&(this.O=[]);this.b=this.a=null};
k.Cb=function(a){var b=this.u,c=this.o;return function(){Di(a,b);Di(a,c)}};k.qf=function(a,b,c,d){var e=Ei(b,Wi,Yi),f;this.v?f=this.v:this.v=f=new Zi(a,e);b.Vc(e);a.enableVertexAttribArray(f.l);a.vertexAttribPointer(f.l,2,5126,!1,28,0);a.enableVertexAttribArray(f.b);a.vertexAttribPointer(f.b,2,5126,!1,28,8);a.enableVertexAttribArray(f.o);a.vertexAttribPointer(f.o,2,5126,!1,28,16);a.enableVertexAttribArray(f.f);a.vertexAttribPointer(f.f,1,5126,!1,28,24);a.uniform2fv(f.I,c);a.uniform1f(f.ta,d);return f};
k.rf=function(a,b){a.disableVertexAttribArray(b.l);a.disableVertexAttribArray(b.b);a.disableVertexAttribArray(b.o);a.disableVertexAttribArray(b.f)};
k.Pd=function(a,b,c,d){var e=a.getParameter(a.DEPTH_FUNC),f=a.getParameter(a.DEPTH_WRITEMASK);d||(a.enable(a.DEPTH_TEST),a.depthMask(!0),a.depthFunc(a.NOTEQUAL));if(tb(c)){var g,h,l;h=this.g[this.g.length-1];for(c=this.l.length-1;0<=c;--c)g=this.l[c],l=this.O[c],nj(this,a,l[0],l[1],l[2]),ui(a,b,g,h),a.clear(a.DEPTH_BUFFER_BIT),h=g}else{var m,n,p,q;p=this.g.length-2;l=h=this.g[p+1];for(g=this.l.length-1;0<=g;--g){m=this.O[g];nj(this,a,m[0],m[1],m[2]);for(m=this.l[g];0<=p&&this.g[p]>=m;)q=this.g[p],
n=this.f[p],n=w(n).toString(),c[n]&&(h!==l&&(ui(a,b,h,l),a.clear(a.DEPTH_BUFFER_BIT)),l=q),p--,h=q;h!==l&&(ui(a,b,h,l),a.clear(a.DEPTH_BUFFER_BIT));h=l=m}}d||(a.disable(a.DEPTH_TEST),a.clear(a.DEPTH_BUFFER_BIT),a.depthMask(f),a.depthFunc(e))};
k.ve=function(a,b,c,d,e){var f,g,h,l,m,n,p;p=this.g.length-2;h=this.g[p+1];for(f=this.l.length-1;0<=f;--f)for(g=this.O[f],nj(this,a,g[0],g[1],g[2]),l=this.l[f];0<=p&&this.g[p]>=l;){g=this.g[p];m=this.f[p];n=w(m).toString();if(void 0===c[n]&&m.U()&&(void 0===e||nb(e,m.U().D()))&&(a.clear(a.COLOR_BUFFER_BIT|a.DEPTH_BUFFER_BIT),ui(a,b,g,h),h=d(m)))return h;p--;h=g}};function nj(a,b,c,d,e){b.uniform4fv(a.v.G,c);b.uniform1f(a.v.qa,d);b.uniform1f(a.v.Z,e)}
k.Na=function(a,b){var c=b.i;this.c.lineCap=void 0!==c?c:"round";c=b.g;this.c.lineDash=c?c:wi;c=b.f;this.c.lineDashOffset=c?c:0;c=b.j;this.c.lineJoin=void 0!==c?c:"round";c=b.a;c instanceof CanvasGradient||c instanceof CanvasPattern?c=xi:c=bd(c).map(function(a,b){return 3!=b?a/255:a})||xi;var d=b.c,d=void 0!==d?d:1,e=b.l,e=void 0!==e?e:10;this.c.strokeColor&&ja(this.c.strokeColor,c)&&this.c.lineWidth===d&&this.c.miterLimit===e||(this.c.s=!0,this.c.strokeColor=c,this.c.lineWidth=d,this.c.miterLimit=
e,this.O.push([c,d,e]))};var fj=3,cj=5,ej=7,dj=11,gj=13,hj=17,ij=19,jj=23;function oj(){this.b="precision mediump float;uniform vec4 e;uniform float f;void main(void){gl_FragColor=e;float alpha=e.a*f;if(alpha==0.0){discard;}gl_FragColor.a=alpha;}"}u(oj,ji);var pj=new oj;function qj(){this.b="attribute vec2 a;uniform mat4 b;uniform mat4 c;uniform mat4 d;void main(void){gl_Position=b*vec4(a,0.0,1.0);}"}u(qj,ki);var rj=new qj;
function sj(a,b){this.G=a.getUniformLocation(b,"e");this.c=a.getUniformLocation(b,"d");this.i=a.getUniformLocation(b,"c");this.a=a.getUniformLocation(b,"f");this.g=a.getUniformLocation(b,"b");this.b=a.getAttribLocation(b,"a")};function tj(a){a=a||{};this.a=void 0!==a.color?a.color:null;this.i=a.lineCap;this.g=void 0!==a.lineDash?a.lineDash:null;this.f=a.lineDashOffset;this.j=a.lineJoin;this.l=a.miterLimit;this.c=a.width;this.b=void 0}k=tj.prototype;k.clone=function(){var a=this.a;return new tj({color:a&&a.slice?a.slice():a||void 0,lineCap:this.i,lineDash:this.g?this.g.slice():void 0,lineDashOffset:this.f,lineJoin:this.j,miterLimit:this.l,width:this.c})};k.Do=function(){return this.a};k.Qk=function(){return this.i};
k.Eo=function(){return this.g};k.Rk=function(){return this.f};k.Sk=function(){return this.j};k.Xk=function(){return this.l};k.Fo=function(){return this.c};k.Go=function(a){this.a=a;this.b=void 0};k.Rp=function(a){this.i=a;this.b=void 0};k.setLineDash=function(a){this.g=a;this.b=void 0};k.Sp=function(a){this.f=a;this.b=void 0};k.Tp=function(a){this.j=a;this.b=void 0};k.Wp=function(a){this.l=a;this.b=void 0};k.Zp=function(a){this.c=a;this.b=void 0};function uj(a){this.b=this.a=this.g=void 0;this.i=void 0===a?!0:a;this.c=0}function vj(a){var b=a.b;if(b){var c=b.next,d=b.ub;c&&(c.ub=d);d&&(d.next=c);a.b=c||d;a.g===a.a?(a.b=void 0,a.g=void 0,a.a=void 0):a.g===b?a.g=a.b:a.a===b&&(a.a=d?a.b.ub:a.b);a.c--}}function wj(a){a.b=a.g;if(a.b)return a.b.data}function xj(a){if(a.b&&a.b.next)return a.b=a.b.next,a.b.data}function yj(a){if(a.b&&a.b.next)return a.b.next.data}function zj(a){if(a.b&&a.b.ub)return a.b=a.b.ub,a.b.data}
function Aj(a){if(a.b&&a.b.ub)return a.b.ub.data}function Bj(a){if(a.b)return a.b.data}uj.prototype.concat=function(a){if(a.b){if(this.b){var b=this.b.next;this.b.next=a.g;a.g.ub=this.b;b.ub=a.a;a.a.next=b;this.c+=a.c}else this.b=a.b,this.g=a.g,this.a=a.a,this.c=a.c;a.b=void 0;a.g=void 0;a.a=void 0;a.c=0}};var Cj,Dj,Ej,Fj;
(function(){var a={},b={ma:a};(function(c){if("object"===typeof a&&"undefined"!==typeof b)b.ma=c();else{var d;"undefined"!==typeof window?d=window:"undefined"!==typeof global?d=global:"undefined"!==typeof self?d=self:d=this;d.Dq=c()}})(function(){return function d(a,b,g){function e(h,l){if(!b[h]){if(!a[h]){var m="function"==typeof require&&require;if(!l&&m)return m(h,!0);if(f)return f(h,!0);m=Error("Cannot find module '"+h+"'");throw m.code="MODULE_NOT_FOUND",m;}m=b[h]={ma:{}};a[h][0].call(m.ma,function(b){var d=
a[h][1][b];return e(d?d:b)},m,m.ma,d,a,b,g)}return b[h].ma}for(var f="function"==typeof require&&require,m=0;m<g.length;m++)e(g[m]);return e}({1:[function(a,b){function d(a,b,f,g,q){f=f||0;g=g||a.length-1;for(q=q||h;g>f;){if(600<g-f){var l=g-f+1,m=b-f+1,p=Math.log(l),n=.5*Math.exp(2*p/3),p=.5*Math.sqrt(p*n*(l-n)/l)*(0>m-l/2?-1:1);d(a,b,Math.max(f,Math.floor(b-m*n/l+p)),Math.min(g,Math.floor(b+(l-m)*n/l+p)),q)}l=a[b];m=f;n=g;e(a,f,b);for(0<q(a[g],l)&&e(a,f,g);m<n;){e(a,m,n);m++;for(n--;0>q(a[m],l);)m++;
for(;0<q(a[n],l);)n--}0===q(a[f],l)?e(a,f,n):(n++,e(a,n,g));n<=b&&(f=n+1);b<=n&&(g=n-1)}}function e(a,b,d){var e=a[b];a[b]=a[d];a[d]=e}function h(a,b){return a<b?-1:a>b?1:0}b.ma=d},{}],2:[function(a,b){function d(a,b){if(!(this instanceof d))return new d(a,b);this.Df=Math.max(4,a||9);this.Xg=Math.max(2,Math.ceil(.4*this.Df));b&&this.ak(b);this.clear()}function e(a,b){h(a,0,a.children.length,b,a)}function h(a,b,d,e,f){f||(f=x(null));f.da=Infinity;f.ga=Infinity;f.ba=-Infinity;f.ja=-Infinity;for(var g;b<
d;b++)g=a.children[b],l(f,a.gb?e(g):g);return f}function l(a,b){a.da=Math.min(a.da,b.da);a.ga=Math.min(a.ga,b.ga);a.ba=Math.max(a.ba,b.ba);a.ja=Math.max(a.ja,b.ja)}function m(a,b){return a.da-b.da}function n(a,b){return a.ga-b.ga}function p(a){return(a.ba-a.da)*(a.ja-a.ga)}function q(a){return a.ba-a.da+(a.ja-a.ga)}function r(a,b){return a.da<=b.da&&a.ga<=b.ga&&b.ba<=a.ba&&b.ja<=a.ja}function v(a,b){return b.da<=a.ba&&b.ga<=a.ja&&b.ba>=a.da&&b.ja>=a.ga}function x(a){return{children:a,height:1,gb:!0,
da:Infinity,ga:Infinity,ba:-Infinity,ja:-Infinity}}function y(a,b,d,e,f){for(var g=[b,d],h;g.length;)d=g.pop(),b=g.pop(),d-b<=e||(h=b+Math.ceil((d-b)/e/2)*e,A(a,h,b,d,f),g.push(b,h,h,d))}b.ma=d;var A=a("quickselect");d.prototype={all:function(){return this.Sg(this.data,[])},search:function(a){var b=this.data,d=[],e=this.xb;if(!v(a,b))return d;for(var f=[],g,h,l,m;b;){g=0;for(h=b.children.length;g<h;g++)l=b.children[g],m=b.gb?e(l):l,v(a,m)&&(b.gb?d.push(l):r(a,m)?this.Sg(l,d):f.push(l));b=f.pop()}return d},
load:function(a){if(!a||!a.length)return this;if(a.length<this.Xg){for(var b=0,d=a.length;b<d;b++)this.Ea(a[b]);return this}a=this.Ug(a.slice(),0,a.length-1,0);this.data.children.length?this.data.height===a.height?this.Zg(this.data,a):(this.data.height<a.height&&(b=this.data,this.data=a,a=b),this.Wg(a,this.data.height-a.height-1,!0)):this.data=a;return this},Ea:function(a){a&&this.Wg(a,this.data.height-1);return this},clear:function(){this.data=x([]);return this},remove:function(a,b){if(!a)return this;
for(var d=this.data,e=this.xb(a),f=[],g=[],h,l,m,p;d||f.length;){d||(d=f.pop(),l=f[f.length-1],h=g.pop(),p=!0);if(d.gb){a:{m=a;var n=d.children,q=b;if(q){for(var v=0;v<n.length;v++)if(q(m,n[v])){m=v;break a}m=-1}else m=n.indexOf(m)}if(-1!==m){d.children.splice(m,1);f.push(d);this.Zj(f);break}}p||d.gb||!r(d,e)?l?(h++,d=l.children[h],p=!1):d=null:(f.push(d),g.push(h),h=0,l=d,d=d.children[0])}return this},xb:function(a){return a},Hf:m,If:n,toJSON:function(){return this.data},Sg:function(a,b){for(var d=
[];a;)a.gb?b.push.apply(b,a.children):d.push.apply(d,a.children),a=d.pop();return b},Ug:function(a,b,d,f){var g=d-b+1,h=this.Df,l;if(g<=h)return l=x(a.slice(b,d+1)),e(l,this.xb),l;f||(f=Math.ceil(Math.log(g)/Math.log(h)),h=Math.ceil(g/Math.pow(h,f-1)));l=x([]);l.gb=!1;l.height=f;var g=Math.ceil(g/h),h=g*Math.ceil(Math.sqrt(h)),m,p,n;for(y(a,b,d,h,this.Hf);b<=d;b+=h)for(p=Math.min(b+h-1,d),y(a,b,p,g,this.If),m=b;m<=p;m+=g)n=Math.min(m+g-1,p),l.children.push(this.Ug(a,m,n,f-1));e(l,this.xb);return l},
Yj:function(a,b,d,e){for(var f,g,h,l,m,n,q,r;;){e.push(b);if(b.gb||e.length-1===d)break;q=r=Infinity;f=0;for(g=b.children.length;f<g;f++)h=b.children[f],m=p(h),n=(Math.max(h.ba,a.ba)-Math.min(h.da,a.da))*(Math.max(h.ja,a.ja)-Math.min(h.ga,a.ga))-m,n<r?(r=n,q=m<q?m:q,l=h):n===r&&m<q&&(q=m,l=h);b=l||b.children[0]}return b},Wg:function(a,b,d){var e=this.xb;d=d?a:e(a);var e=[],f=this.Yj(d,this.data,b,e);f.children.push(a);for(l(f,d);0<=b;)if(e[b].children.length>this.Df)this.fk(e,b),b--;else break;this.Vj(d,
e,b)},fk:function(a,b){var d=a[b],f=d.children.length,g=this.Xg;this.Wj(d,g,f);f=this.Xj(d,g,f);f=x(d.children.splice(f,d.children.length-f));f.height=d.height;f.gb=d.gb;e(d,this.xb);e(f,this.xb);b?a[b-1].children.push(f):this.Zg(d,f)},Zg:function(a,b){this.data=x([a,b]);this.data.height=a.height+1;this.data.gb=!1;e(this.data,this.xb)},Xj:function(a,b,d){var e,f,g,l,m,n,q;m=n=Infinity;for(e=b;e<=d-b;e++)f=h(a,0,e,this.xb),g=h(a,e,d,this.xb),l=Math.max(0,Math.min(f.ba,g.ba)-Math.max(f.da,g.da))*Math.max(0,
Math.min(f.ja,g.ja)-Math.max(f.ga,g.ga)),f=p(f)+p(g),l<m?(m=l,q=e,n=f<n?f:n):l===m&&f<n&&(n=f,q=e);return q},Wj:function(a,b,d){var e=a.gb?this.Hf:m,f=a.gb?this.If:n,g=this.Tg(a,b,d,e);b=this.Tg(a,b,d,f);g<b&&a.children.sort(e)},Tg:function(a,b,d,e){a.children.sort(e);e=this.xb;var f=h(a,0,b,e),g=h(a,d-b,d,e),m=q(f)+q(g),n,p;for(n=b;n<d-b;n++)p=a.children[n],l(f,a.gb?e(p):p),m+=q(f);for(n=d-b-1;n>=b;n--)p=a.children[n],l(g,a.gb?e(p):p),m+=q(g);return m},Vj:function(a,b,d){for(;0<=d;d--)l(b[d],a)},
Zj:function(a){for(var b=a.length-1,d;0<=b;b--)0===a[b].children.length?0<b?(d=a[b-1].children,d.splice(d.indexOf(a[b]),1)):this.clear():e(a[b],this.xb)},ak:function(a){var b=["return a"," - b",";"];this.Hf=new Function("a","b",b.join(a[0]));this.If=new Function("a","b",b.join(a[1]));this.xb=new Function("a","return {minX: a"+a[0]+", minY: a"+a[1]+", maxX: a"+a[2]+", maxY: a"+a[3]+"};")}}},{quickselect:1}]},{},[2])(2)});Cj=b.ma})();function Gj(a){this.b=Cj(a);this.a={}}k=Gj.prototype;k.Ea=function(a,b){var c={da:a[0],ga:a[1],ba:a[2],ja:a[3],value:b};this.b.Ea(c);this.a[w(b)]=c};k.load=function(a,b){for(var c=Array(b.length),d=0,e=b.length;d<e;d++){var f=a[d],g=b[d],f={da:f[0],ga:f[1],ba:f[2],ja:f[3],value:g};c[d]=f;this.a[w(g)]=f}this.b.load(c)};k.remove=function(a){a=w(a);var b=this.a[a];delete this.a[a];return null!==this.b.remove(b)};
function Hj(a,b,c){var d=a.a[w(c)];$a([d.da,d.ga,d.ba,d.ja],b)||(a.remove(c),a.Ea(b,c))}function Ij(a){return a.b.all().map(function(a){return a.value})}function Jj(a,b){return a.b.search({da:b[0],ga:b[1],ba:b[2],ja:b[3]}).map(function(a){return a.value})}k.forEach=function(a,b){return Kj(Ij(this),a,b)};function Lj(a,b,c,d){return Kj(Jj(a,b),c,d)}function Kj(a,b,c){for(var d,e=0,f=a.length;e<f&&!(d=b.call(c,a[e]));e++);return d}k.clear=function(){this.b.clear();this.a={}};
k.D=function(a){var b=this.b.data;return Wa(b.da,b.ga,b.ba,b.ja,a)};function Mj(a,b){si.call(this,0,b);this.j=new $i(0,b);this.v=null;this.O=[];this.c=[];this.l={fillColor:null,s:!1}}u(Mj,si);function Nj(a,b,c,d){var e=new uj,f=new Gj;b=Oj(a,b,d,e,f,!0);if(c.length){var g,h,l=[];g=0;for(h=c.length;g<h;++g){var m={list:new uj,ba:void 0};l.push(m);m.ba=Oj(a,c[g],d,m.list,f,!1)}l.sort(function(a,b){return b.ba-a.ba});for(g=0;g<l.length;++g)Pj(l[g].list,l[g].ba,e,b,f)}Qj(e,f,!1);Rj(a,e,f)}
function Oj(a,b,c,d,e,f){var g,h,l=a.a.length/2,m,n,p,q=[],r=[];if(f===Pf(b,0,b.length,c))for(n=m=Sj(a,b[0],b[1],l++),f=b[0],g=c,h=b.length;g<h;g+=c)p=Sj(a,b[g],b[g+1],l++),r.push(Tj(n,p,d)),q.push([Math.min(n.x,p.x),Math.min(n.y,p.y),Math.max(n.x,p.x),Math.max(n.y,p.y)]),f=b[g]>f?b[g]:f,n=p;else for(g=b.length-c,n=m=Sj(a,b[g],b[g+1],l++),f=b[g],g-=c,h=0;g>=h;g-=c)p=Sj(a,b[g],b[g+1],l++),r.push(Tj(n,p,d)),q.push([Math.min(n.x,p.x),Math.min(n.y,p.y),Math.max(n.x,p.x),Math.max(n.y,p.y)]),f=b[g]>f?b[g]:
f,n=p;r.push(Tj(p,m,d));q.push([Math.min(n.x,p.x),Math.min(n.y,p.y),Math.max(n.x,p.x),Math.max(n.y,p.y)]);e.load(q,r);return f}function Qj(a,b,c){var d=wj(a),e=d,f=xj(a),g=!1;do{var h=c?yi(f.X.x,f.X.y,e.X.x,e.X.y,e.aa.x,e.aa.y):yi(e.aa.x,e.aa.y,e.X.x,e.X.y,f.X.x,f.X.y);void 0===h?(Uj(e,f,a,b),g=!0,f===d&&(d=yj(a)),f=e,zj(a)):e.X.vb!==h&&(e.X.vb=h,g=!0);e=f;f=xj(a)}while(e!==d);return g}
function Pj(a,b,c,d,e){Qj(a,e,!0);for(var f=wj(a);f.X.x!==b;)f=xj(a);b=f.X;d={x:d,y:b.y,fb:-1};var g=Infinity,h,l,m,n;m=Vj({aa:b,X:d},e,!0);h=0;for(l=m.length;h<l;++h){var p=m[h];if(void 0===p.aa.vb){var q=Wj(b,d,p.aa,p.X,!0),r=Math.abs(b.x-q[0]);r<g&&(g=r,n={x:q[0],y:q[1],fb:-1},f=p)}}if(Infinity!==g){m=f.X;if(0<g&&(f=Xj(b,n,f.X,e),f.length))for(n=Infinity,h=0,l=f.length;h<l;++h)if(g=f[h],p=Math.atan2(b.y-g.y,d.x-g.x),p<n||p===n&&g.x<m.x)n=p,m=g;for(f=wj(c);f.X!==m;)f=xj(c);d={x:b.x,y:b.y,fb:b.fb,
vb:void 0};h={x:f.X.x,y:f.X.y,fb:f.X.fb,vb:void 0};yj(a).aa=d;Tj(b,f.X,a,e);Tj(h,d,a,e);f.X=h;a.i&&a.b&&(a.g=a.b,a.a=a.b.ub);c.concat(a)}}
function Rj(a,b,c){for(var d=!1,e=Yj(b,c);3<b.c;)if(e){if(!Zj(a,b,c,e,d)&&!Qj(b,c,d)&&!ak(a,b,c,!0))break}else if(!Zj(a,b,c,e,d)&&!Qj(b,c,d)&&!ak(a,b,c))if(e=Yj(b,c)){var d=b,f=2*d.c,g=Array(f),h=wj(d),l=h,m=0;do g[m++]=l.aa.x,g[m++]=l.aa.y,l=xj(d);while(l!==h);d=!Pf(g,0,f,2);Qj(b,c,d)}else{e=a;d=b;f=g=wj(d);do{h=Vj(f,c);if(h.length){g=h[0];h=Wj(f.aa,f.X,g.aa,g.X);h=Sj(e,h[0],h[1],e.a.length/2);l=new uj;m=new Gj;Tj(h,f.X,l,m);f.X=h;Hj(c,[Math.min(f.aa.x,h.x),Math.min(f.aa.y,h.y),Math.max(f.aa.x,h.x),
Math.max(f.aa.y,h.y)],f);for(f=xj(d);f!==g;)Tj(f.aa,f.X,l,m),c.remove(f),vj(d),f=Bj(d);Tj(g.aa,h,l,m);g.aa=h;Hj(c,[Math.min(g.X.x,h.x),Math.min(g.X.y,h.y),Math.max(g.X.x,h.x),Math.max(g.X.y,h.y)],g);Qj(d,c,!1);Rj(e,d,c);Qj(l,m,!1);Rj(e,l,m);break}f=xj(d)}while(f!==g);break}3===b.c&&(e=a.b.length,a.b[e++]=Aj(b).aa.fb,a.b[e++]=Bj(b).aa.fb,a.b[e++]=yj(b).aa.fb)}
function Zj(a,b,c,d,e){var f=a.b.length,g=wj(b),h=Aj(b),l=g,m=xj(b),n=yj(b),p,q,r,v=!1;do{p=l.aa;q=l.X;r=m.X;if(!1===q.vb){var x=e?bk(n.X,r,q,p,h.aa):bk(h.aa,p,q,r,n.X);!d&&Vj({aa:p,X:r},c).length||!x||Xj(p,q,r,c,!0).length||!d&&!1!==p.vb&&!1!==r.vb&&Pf([h.aa.x,h.aa.y,p.x,p.y,q.x,q.y,r.x,r.y,n.X.x,n.X.y],0,10,2)!==!e||(a.b[f++]=p.fb,a.b[f++]=q.fb,a.b[f++]=r.fb,Uj(l,m,b,c),m===g&&(g=n),v=!0)}h=Aj(b);l=Bj(b);m=xj(b);n=yj(b)}while(l!==g&&3<b.c);return v}
function ak(a,b,c,d){var e=wj(b);xj(b);var f=e,g=xj(b),h=!1;do{var l=Wj(f.aa,f.X,g.aa,g.X,d);if(l){var m,h=a.b.length,n=a.a.length/2,p=zj(b);vj(b);c.remove(p);m=p===e;d?(l[0]===f.aa.x&&l[1]===f.aa.y?(zj(b),l=f.aa,g.aa=l,c.remove(f),m=m||f===e):(l=g.X,f.X=l,c.remove(g),m=m||g===e),vj(b)):(l=Sj(a,l[0],l[1],n),f.X=l,g.aa=l,Hj(c,[Math.min(f.aa.x,f.X.x),Math.min(f.aa.y,f.X.y),Math.max(f.aa.x,f.X.x),Math.max(f.aa.y,f.X.y)],f),Hj(c,[Math.min(g.aa.x,g.X.x),Math.min(g.aa.y,g.X.y),Math.max(g.aa.x,g.X.x),Math.max(g.aa.y,
g.X.y)],g));a.b[h++]=p.aa.fb;a.b[h++]=p.X.fb;a.b[h++]=l.fb;h=!0;if(m)break}f=Aj(b);g=xj(b)}while(f!==e);return h}function Yj(a,b){var c=wj(a),d=c;do{if(Vj(d,b).length)return!1;d=xj(a)}while(d!==c);return!0}function Sj(a,b,c,d){var e=a.a.length;a.a[e++]=b;a.a[e++]=c;return{x:b,y:c,fb:d,vb:void 0}}
function Tj(a,b,c,d){var e={aa:a,X:b},f={ub:void 0,next:void 0,data:e},g=c.b;if(g){var h=g.next;f.ub=g;f.next=h;g.next=f;h&&(h.ub=f);g===c.a&&(c.a=f)}else c.g=f,c.a=f,c.i&&(f.next=f,f.ub=f);c.b=f;c.c++;d&&d.Ea([Math.min(a.x,b.x),Math.min(a.y,b.y),Math.max(a.x,b.x),Math.max(a.y,b.y)],e);return e}function Uj(a,b,c,d){Bj(c)===b&&(vj(c),a.X=b.X,d.remove(b),Hj(d,[Math.min(a.aa.x,a.X.x),Math.min(a.aa.y,a.X.y),Math.max(a.aa.x,a.X.x),Math.max(a.aa.y,a.X.y)],a))}
function Xj(a,b,c,d,e){var f,g,h,l=[],m=Jj(d,[Math.min(a.x,b.x,c.x),Math.min(a.y,b.y,c.y),Math.max(a.x,b.x,c.x),Math.max(a.y,b.y,c.y)]);d=0;for(f=m.length;d<f;++d)for(g in m[d])h=m[d][g],"object"!==typeof h||e&&!h.vb||h.x===a.x&&h.y===a.y||h.x===b.x&&h.y===b.y||h.x===c.x&&h.y===c.y||-1!==l.indexOf(h)||!Jf([a.x,a.y,b.x,b.y,c.x,c.y],0,6,2,h.x,h.y)||l.push(h);return l}
function Vj(a,b,c){var d=a.aa,e=a.X;b=Jj(b,[Math.min(d.x,e.x),Math.min(d.y,e.y),Math.max(d.x,e.x),Math.max(d.y,e.y)]);var f=[],g,h;g=0;for(h=b.length;g<h;++g){var l=b[g];a!==l&&(c||l.aa!==e||l.X!==d)&&Wj(d,e,l.aa,l.X,c)&&f.push(l)}return f}
function Wj(a,b,c,d,e){var f=(d.y-c.y)*(b.x-a.x)-(d.x-c.x)*(b.y-a.y);if(f&&(d=((d.x-c.x)*(a.y-c.y)-(d.y-c.y)*(a.x-c.x))/f,c=((b.x-a.x)*(a.y-c.y)-(b.y-a.y)*(a.x-c.x))/f,!e&&d>zi&&d<1-zi&&c>zi&&c<1-zi||e&&0<=d&&1>=d&&0<=c&&1>=c))return[a.x+d*(b.x-a.x),a.y+d*(b.y-a.y)]}
function bk(a,b,c,d,e){if(void 0===b.vb||void 0===d.vb)return!1;var f=(c.x-d.x)*(b.y-d.y)>(c.y-d.y)*(b.x-d.x);e=(e.x-d.x)*(b.y-d.y)<(e.y-d.y)*(b.x-d.x);a=(a.x-b.x)*(d.y-b.y)>(a.y-b.y)*(d.x-b.x);c=(c.x-b.x)*(d.y-b.y)<(c.y-b.y)*(d.x-b.x);b=b.vb?c||a:c&&a;return(d.vb?e||f:e&&f)&&b}k=Mj.prototype;
k.rc=function(a,b){var c=a.md(),d=a.sa(),e=this.b.length,f=this.j.b.length,g,h,l,m;g=0;for(h=c.length;g<h;++g){var n=c[g].Oc();if(0<n.length){var p=n[0].ia(),p=nf(p,p.length,d,-this.origin[0],-this.origin[1]),q=[],r;l=1;for(m=n.length;l<m;++l)r=n[l].ia(),r=nf(r,r.length,d,-this.origin[0],-this.origin[1]),q.push(r);lj(this.j,p,q,d);Nj(this,p,q,d)}}this.b.length>e&&(this.g.push(e),this.f.push(b),this.l.s&&(this.c.push(e),this.l.s=!1));this.j.b.length>f&&mj(this.j,b,f)};
k.tc=function(a,b){var c=a.Oc(),d=a.sa();if(0<c.length){this.g.push(this.b.length);this.f.push(b);this.l.s&&(this.c.push(this.b.length),this.l.s=!1);mj(this.j,b);var e=c[0].ia(),e=nf(e,e.length,d,-this.origin[0],-this.origin[1]),f=[],g,h,l;g=1;for(h=c.length;g<h;++g)l=c[g].ia(),l=nf(l,l.length,d,-this.origin[0],-this.origin[1]),f.push(l);lj(this.j,e,f,d);Nj(this,e,f,d)}};
k.Bb=function(a){this.u=new Ai(this.a);this.o=new Ai(this.b);this.g.push(this.b.length);this.j.Bb(a);!this.c.length&&0<this.O.length&&(this.O=[]);this.b=this.a=null};k.Cb=function(a){var b=this.u,c=this.o,d=this.j.Cb(a);return function(){Di(a,b);Di(a,c);d()}};k.qf=function(a,b){var c=Ei(b,pj,rj),d;this.v?d=this.v:this.v=d=new sj(a,c);b.Vc(c);a.enableVertexAttribArray(d.b);a.vertexAttribPointer(d.b,2,5126,!1,8,0);return d};k.rf=function(a,b){a.disableVertexAttribArray(b.b)};
k.Pd=function(a,b,c,d){var e=a.getParameter(a.DEPTH_FUNC),f=a.getParameter(a.DEPTH_WRITEMASK);d||(a.enable(a.DEPTH_TEST),a.depthMask(!0),a.depthFunc(a.NOTEQUAL));if(tb(c)){var g,h,l;h=this.g[this.g.length-1];for(c=this.c.length-1;0<=c;--c)g=this.c[c],l=this.O[c],a.uniform4fv(this.v.G,l),ui(a,b,g,h),h=g}else{var m,n,p,q;p=this.g.length-2;l=h=this.g[p+1];for(g=this.c.length-1;0<=g;--g){m=this.O[g];a.uniform4fv(this.v.G,m);for(m=this.c[g];0<=p&&this.g[p]>=m;)q=this.g[p],n=this.f[p],n=w(n).toString(),
c[n]&&(h!==l&&(ui(a,b,h,l),a.clear(a.DEPTH_BUFFER_BIT)),l=q),p--,h=q;h!==l&&(ui(a,b,h,l),a.clear(a.DEPTH_BUFFER_BIT));h=l=m}}d||(a.disable(a.DEPTH_TEST),a.clear(a.DEPTH_BUFFER_BIT),a.depthMask(f),a.depthFunc(e))};
k.ve=function(a,b,c,d,e){var f,g,h,l,m,n,p;p=this.g.length-2;h=this.g[p+1];for(f=this.c.length-1;0<=f;--f)for(g=this.O[f],a.uniform4fv(this.v.G,g),l=this.c[f];0<=p&&this.g[p]>=l;){g=this.g[p];m=this.f[p];n=w(m).toString();if(void 0===c[n]&&m.U()&&(void 0===e||nb(e,m.U().D()))&&(a.clear(a.COLOR_BUFFER_BIT|a.DEPTH_BUFFER_BIT),ui(a,b,g,h),h=d(m)))return h;p--;h=g}};
k.Na=function(a,b){var c=a?a.b:[0,0,0,0];c instanceof CanvasGradient||c instanceof CanvasPattern?c=vi:c=bd(c).map(function(a,b){return 3!=b?a/255:a})||vi;this.l.fillColor&&ja(c,this.l.fillColor)||(this.l.fillColor=c,this.l.s=!0,this.O.push(c));b?this.j.Na(null,b):this.j.Na(null,new tj({color:[0,0,0,0],lineWidth:0}))};function ck(){}ck.prototype.i=function(){};function dk(a,b,c){this.f=b;this.j=a;this.c=c;this.a={}}u(dk,hi);function ek(a,b){var c=[],d;for(d in a.a){var e=a.a[d],f;for(f in e)c.push(e[f].Cb(b))}return function(){for(var a=c.length,b,d=0;d<a;d++)b=c[d].apply(this,arguments);return b}}function fk(a,b){for(var c in a.a){var d=a.a[c],e;for(e in d)d[e].Bb(b)}}dk.prototype.b=function(a,b){var c=void 0!==a?a.toString():"0",d=this.a[c];void 0===d&&(d={},this.a[c]=d);c=d[b];void 0===c&&(c=new gk[b](this.j,this.f),d[b]=c);return c};
dk.prototype.g=function(){return tb(this.a)};dk.prototype.i=function(a,b,c,d,e,f,g,h){var l=Object.keys(this.a).map(Number);l.sort(ea);var m,n,p,q,r,v;m=0;for(n=l.length;m<n;++m)for(r=this.a[l[m].toString()],p=0,q=gi.length;p<q;++p)v=r[gi[p]],void 0!==v&&v.i(a,b,c,d,e,f,g,h,void 0,!1)};
function hk(a,b,c,d,e,f,g,h,l,m,n){var p=ik,q=Object.keys(a.a).map(Number);q.sort(function(a,b){return b-a});var r,v,x,y,A;r=0;for(v=q.length;r<v;++r)for(y=a.a[q[r].toString()],x=gi.length-1;0<=x;--x)if(A=y[gi[x]],void 0!==A&&(A=A.i(b,c,d,e,p,f,g,h,l,m,n)))return A}
dk.prototype.Ba=function(a,b,c,d,e,f,g,h,l,m){var n=b.b;n.bindFramebuffer(n.FRAMEBUFFER,Mi(b));var p;void 0!==this.c&&(p=Ma(Xa(a),d*this.c));return hk(this,b,a,d,e,g,h,l,function(a){var b=new Uint8Array(4);n.readPixels(0,0,1,1,n.RGBA,n.UNSIGNED_BYTE,b);if(0<b[3]&&(a=m(a)))return a},!0,p)};
function jk(a,b,c,d,e,f,g,h){var l=c.b;l.bindFramebuffer(l.FRAMEBUFFER,Mi(c));return void 0!==hk(a,c,b,d,e,f,g,h,function(){var a=new Uint8Array(4);l.readPixels(0,0,1,1,l.RGBA,l.UNSIGNED_BYTE,a);return 0<a[3]},!1)}var ik=[1,1],gk={Circle:Ci,Image:Ri,LineString:$i,Polygon:Mj,Text:ck};function kk(a,b,c,d,e,f,g){this.b=a;this.g=b;this.a=f;this.c=g;this.j=e;this.f=d;this.i=c;this.l=this.o=this.u=null}u(kk,Th);k=kk.prototype;k.td=function(a){this.Na(a.Ca(),a.Da());this.Wb(a.Y())};
k.oc=function(a){switch(a.S()){case "Point":this.sc(a,null);break;case "LineString":this.Rb(a,null);break;case "Polygon":this.tc(a,null);break;case "MultiPoint":this.qc(a,null);break;case "MultiLineString":this.pc(a,null);break;case "MultiPolygon":this.rc(a,null);break;case "GeometryCollection":this.ue(a,null);break;case "Circle":this.ac(a,null)}};k.te=function(a,b){var c=(0,b.Qa)(a);c&&nb(this.a,c.D())&&(this.td(b),this.oc(c))};k.ue=function(a){a=a.a;var b,c;b=0;for(c=a.length;b<c;++b)this.oc(a[b])};
k.sc=function(a,b){var c=this.b,d=(new dk(1,this.a)).b(0,"Image");d.Wb(this.u);d.sc(a,b);d.Bb(c);d.i(this.b,this.g,this.i,this.f,this.j,this.c,1,{},void 0,!1);d.Cb(c)()};k.qc=function(a,b){var c=this.b,d=(new dk(1,this.a)).b(0,"Image");d.Wb(this.u);d.qc(a,b);d.Bb(c);d.i(this.b,this.g,this.i,this.f,this.j,this.c,1,{},void 0,!1);d.Cb(c)()};
k.Rb=function(a,b){var c=this.b,d=(new dk(1,this.a)).b(0,"LineString");d.Na(null,this.l);d.Rb(a,b);d.Bb(c);d.i(this.b,this.g,this.i,this.f,this.j,this.c,1,{},void 0,!1);d.Cb(c)()};k.pc=function(a,b){var c=this.b,d=(new dk(1,this.a)).b(0,"LineString");d.Na(null,this.l);d.pc(a,b);d.Bb(c);d.i(this.b,this.g,this.i,this.f,this.j,this.c,1,{},void 0,!1);d.Cb(c)()};
k.tc=function(a,b){var c=this.b,d=(new dk(1,this.a)).b(0,"Polygon");d.Na(this.o,this.l);d.tc(a,b);d.Bb(c);d.i(this.b,this.g,this.i,this.f,this.j,this.c,1,{},void 0,!1);d.Cb(c)()};k.rc=function(a,b){var c=this.b,d=(new dk(1,this.a)).b(0,"Polygon");d.Na(this.o,this.l);d.rc(a,b);d.Bb(c);d.i(this.b,this.g,this.i,this.f,this.j,this.c,1,{},void 0,!1);d.Cb(c)()};
k.ac=function(a,b){var c=this.b,d=(new dk(1,this.a)).b(0,"Circle");d.Na(this.o,this.l);d.ac(a,b);d.Bb(c);d.i(this.b,this.g,this.i,this.f,this.j,this.c,1,{},void 0,!1);d.Cb(c)()};k.Wb=function(a){this.u=a};k.Na=function(a,b){this.o=a;this.l=b};function lk(){this.c=0;this.b={};this.g=this.a=null}k=lk.prototype;k.clear=function(){this.c=0;this.b={};this.g=this.a=null};k.forEach=function(a,b){for(var c=this.a;c;)a.call(b,c.cd,c.wc,this),c=c.Mb};k.get=function(a){a=this.b[a];sa(!!a,15);if(a===this.g)return a.cd;a===this.a?(this.a=this.a.Mb,this.a.xd=null):(a.Mb.xd=a.xd,a.xd.Mb=a.Mb);a.Mb=null;a.xd=this.g;this.g=this.g.Mb=a;return a.cd};
k.pop=function(){var a=this.a;delete this.b[a.wc];a.Mb&&(a.Mb.xd=null);this.a=a.Mb;this.a||(this.g=null);--this.c;return a.cd};k.replace=function(a,b){this.get(a);this.b[a].cd=b};k.set=function(a,b){sa(!(a in this.b),16);var c={wc:a,Mb:null,xd:this.g,cd:b};this.g?this.g.Mb=c:this.a=c;this.g=c;this.b[a]=c;++this.c};function mk(a,b){Jh.call(this,0,b);this.b=document.createElement("CANVAS");this.b.style.width="100%";this.b.style.height="100%";this.b.style.display="block";this.b.className="ol-unselectable";a.insertBefore(this.b,a.childNodes[0]||null);this.O=this.A=0;this.C=hd();this.o=!0;this.g=Md(this.b,{antialias:!0,depth:!0,failIfMajorPerformanceCaveat:!0,preserveDrawingBuffer:!1,stencil:!0});this.i=new Li(this.b,this.g);z(this.b,"webglcontextlost",this.On,this);z(this.b,"webglcontextrestored",this.Pn,this);
this.a=new lk;this.v=null;this.j=new Ie(function(a){var b=a[1];a=a[2];var c=b[0]-this.v[0],b=b[1]-this.v[1];return 65536*Math.log(a)+Math.sqrt(c*c+b*b)/a}.bind(this),function(a){return a[0].hb()});this.G=function(){if(this.j.b.length){Me(this.j);var a=Je(this.j);nk(this,a[0],a[3],a[4])}return!1}.bind(this);this.f=0;ok(this)}u(mk,Jh);
function nk(a,b,c,d){var e=a.g,f=b.hb();if(a.a.b.hasOwnProperty(f))a=a.a.get(f),e.bindTexture(3553,a.Fb),9729!=a.Ih&&(e.texParameteri(3553,10240,9729),a.Ih=9729),9729!=a.Kh&&(e.texParameteri(3553,10241,9729),a.Kh=9729);else{var g=e.createTexture();e.bindTexture(3553,g);if(0<d){var h=a.C.canvas,l=a.C;a.A!==c[0]||a.O!==c[1]?(h.width=c[0],h.height=c[1],a.A=c[0],a.O=c[1]):l.clearRect(0,0,c[0],c[1]);l.drawImage(b.Y(),d,d,c[0],c[1],0,0,c[0],c[1]);e.texImage2D(3553,0,6408,6408,5121,h)}else e.texImage2D(3553,
0,6408,6408,5121,b.Y());e.texParameteri(3553,10240,9729);e.texParameteri(3553,10241,9729);e.texParameteri(3553,10242,33071);e.texParameteri(3553,10243,33071);a.a.set(f,{Fb:g,Ih:9729,Kh:9729})}}function pk(a,b,c){var d=a.l;if(Oc(d,b)){a=a.i;var e=c.viewState;d.b(new Oh(b,new kk(a,e.center,e.resolution,e.rotation,c.size,c.extent,c.pixelRatio),c,null,a))}}k=mk.prototype;k.ra=function(){var a=this.g;a.isContextLost()||this.a.forEach(function(b){b&&a.deleteTexture(b.Fb)});Kc(this.i);Jh.prototype.ra.call(this)};
k.tk=function(a,b){for(var c=this.g,d;1024<this.a.c-this.f;){if(d=this.a.a.cd)c.deleteTexture(d.Fb);else if(+this.a.a.wc==b.index)break;else--this.f;this.a.pop()}};k.S=function(){return"webgl"};k.On=function(a){a.preventDefault();this.a.clear();this.f=0;a=this.c;for(var b in a)a[b].hg()};k.Pn=function(){ok(this);this.l.render()};function ok(a){a=a.g;a.activeTexture(33984);a.blendFuncSeparate(770,771,1,771);a.disable(2884);a.disable(2929);a.disable(3089);a.disable(2960)}
k.Dg=function(a){var b=this.i,c=this.g;if(c.isContextLost())return!1;if(!a)return this.o&&(this.b.style.display="none",this.o=!1),!1;this.v=a.focus;this.a.set((-a.index).toString(),null);++this.f;pk(this,"precompose",a);var d=[],e=a.layerStatesArray;ka(e);var f=a.viewState.resolution,g,h,l,m;g=0;for(h=e.length;g<h;++g)m=e[g],uh(m,f)&&"ready"==m.uj&&(l=Mh(this,m.layer),l.ig(a,m,b)&&d.push(m));e=a.size[0]*a.pixelRatio;f=a.size[1]*a.pixelRatio;if(this.b.width!=e||this.b.height!=f)this.b.width=e,this.b.height=
f;c.bindFramebuffer(36160,null);c.clearColor(0,0,0,0);c.clear(16384);c.enable(3042);c.viewport(0,0,this.b.width,this.b.height);g=0;for(h=d.length;g<h;++g)m=d[g],l=Mh(this,m.layer),l.zi(a,m,b);this.o||(this.b.style.display="",this.o=!0);Kh(a);1024<this.a.c-this.f&&a.postRenderFunctions.push(this.tk.bind(this));this.j.b.length&&(a.postRenderFunctions.push(this.G),a.animate=!0);pk(this,"postcompose",a);Nh(this,a);a.postRenderFunctions.push(Lh)};
k.Ba=function(a,b,c,d,e,f,g){var h;if(this.g.isContextLost())return!1;var l=b.viewState,m=b.layerStatesArray,n;for(n=m.length-1;0<=n;--n){h=m[n];var p=h.layer;if(uh(h,l.resolution)&&f.call(g,p)&&(h=Mh(this,p).Ba(a,b,c,d,e)))return h}};k.xi=function(a,b,c,d,e){c=!1;if(this.g.isContextLost())return!1;var f=b.viewState,g=b.layerStatesArray,h;for(h=g.length-1;0<=h;--h){var l=g[h],m=l.layer;if(uh(l,f.resolution)&&d.call(e,m)&&(c=Mh(this,m).Te(a,b)))return!0}return c};
k.wi=function(a,b,c,d,e){if(this.g.isContextLost())return!1;var f=b.viewState,g,h=b.layerStatesArray,l;for(l=h.length-1;0<=l;--l){g=h[l];var m=g.layer;if(uh(g,f.resolution)&&e.call(d,m)&&(g=Mh(this,m).gg(a,b,c,d)))return g}};var qk=["canvas","webgl"];
function H(a){Qc.call(this);var b=rk(a);this.yf=void 0!==a.loadTilesWhileAnimating?a.loadTilesWhileAnimating:!1;this.zf=void 0!==a.loadTilesWhileInteracting?a.loadTilesWhileInteracting:!1;this.Ef=void 0!==a.pixelRatio?a.pixelRatio:Td;this.wf=b.logos;this.fa=function(){this.f=void 0;this.Ip.call(this,Date.now())}.bind(this);this.Gb=yh();this.Ff=yh();this.le=0;this.a=null;this.yb=Ja();this.G=this.I=this.Z=null;this.c=document.createElement("DIV");this.c.className="ol-viewport"+(Yd?" ol-touch":"");this.c.style.position=
"relative";this.c.style.overflow="hidden";this.c.style.width="100%";this.c.style.height="100%";this.c.style.msTouchAction="none";this.c.style.touchAction="none";this.A=document.createElement("DIV");this.A.className="ol-overlaycontainer";this.c.appendChild(this.A);this.v=document.createElement("DIV");this.v.className="ol-overlaycontainer-stopevent";a="click dblclick mousedown touchstart MSPointerDown pointerdown mousewheel wheel".split(" ");for(var c=0,d=a.length;c<d;++c)z(this.v,a[c],Mc);this.c.appendChild(this.v);
this.Ja=new Fe(this);for(var e in Id)z(this.Ja,Id[e],this.Bh,this);this.na=b.keyboardEventTarget;this.u=null;z(this.c,"wheel",this.pd,this);z(this.c,"mousewheel",this.pd,this);this.l=b.controls;this.j=b.interactions;this.o=b.overlays;this.lg={};this.C=new b.Kp(this.c,this);this.T=null;this.Va=[];this.Ha=new Ne(this.ll.bind(this),this.Rl.bind(this));this.ea={};z(this,Sc("layergroup"),this.zl,this);z(this,Sc("view"),this.Sl,this);z(this,Sc("size"),this.Ol,this);z(this,Sc("target"),this.Ql,this);this.H(b.values);
this.l.forEach(function(a){a.setMap(this)},this);z(this.l,"add",function(a){a.element.setMap(this)},this);z(this.l,"remove",function(a){a.element.setMap(null)},this);this.j.forEach(function(a){a.setMap(this)},this);z(this.j,"add",function(a){a.element.setMap(this)},this);z(this.j,"remove",function(a){a.element.setMap(null)},this);this.o.forEach(this.bh,this);z(this.o,"add",function(a){this.bh(a.element)},this);z(this.o,"remove",function(a){var b=a.element.f;void 0!==b&&delete this.lg[b.toString()];
a.element.setMap(null)},this)}u(H,Qc);k=H.prototype;k.gk=function(a){this.l.push(a)};k.hk=function(a){this.j.push(a)};k.$g=function(a){this.Mc().sd().push(a)};k.ah=function(a){this.o.push(a)};k.bh=function(a){var b=a.f;void 0!==b&&(this.lg[b.toString()]=a);a.setMap(this)};
k.ra=function(){Kc(this.Ja);Kc(this.C);Hc(this.c,"wheel",this.pd,this);Hc(this.c,"mousewheel",this.pd,this);this.i&&(window.removeEventListener("resize",this.i,!1),this.i=void 0);this.f&&(cancelAnimationFrame(this.f),this.f=void 0);this.Ke(null);Qc.prototype.ra.call(this)};k.we=function(a,b,c){if(this.a)return a=this.Xa(a),c=c?c:{},this.C.Ba(a,this.a,void 0!==c.hitTolerance?c.hitTolerance*this.a.pixelRatio:0,b,null,c.layerFilter?c.layerFilter:jf,null)};
k.Em=function(a,b,c,d,e){if(this.a)return this.C.wi(a,this.a,b,void 0!==c?c:null,d?d:jf,void 0!==e?e:null)};k.Tl=function(a,b){if(!this.a)return!1;var c=this.Xa(a);b=b?b:{};return this.C.xi(c,this.a,void 0!==b.hitTolerance?b.hitTolerance*this.a.pixelRatio:0,b.layerFilter?b.layerFilter:jf,null)};k.Of=function(a){return this.Xa(this.xe(a))};k.xe=function(a){var b=this.c.getBoundingClientRect();a=a.changedTouches?a.changedTouches[0]:a;return[a.clientX-b.left,a.clientY-b.top]};k.Wf=function(){return this.get("target")};
k.vc=function(){var a=this.Wf();return void 0!==a?"string"===typeof a?document.getElementById(a):a:null};k.Xa=function(a){var b=this.a;return b?Dh(b.pixelToCoordinateTransform,a.slice()):null};k.Hk=function(){return this.l};k.al=function(){return this.o};k.$k=function(a){a=this.lg[a.toString()];return void 0!==a?a:null};k.Nk=function(){return this.j};k.Mc=function(){return this.get("layergroup")};k.Qh=function(){return this.Mc().sd()};
k.Ka=function(a){var b=this.a;return b?Dh(b.coordinateToPixelTransform,a.slice(0,2)):null};k.Nb=function(){return this.get("size")};k.$=function(){return this.get("view")};k.nl=function(){return this.c};k.ll=function(a,b,c,d){var e=this.a;if(!(e&&b in e.wantedTiles&&e.wantedTiles[b][a.hb()]))return Infinity;a=c[0]-e.focus[0];c=c[1]-e.focus[1];return 65536*Math.log(d)+Math.sqrt(a*a+c*c)/d};k.pd=function(a,b){var c=new Hd(b||a.type,this,a);this.Bh(c)};
k.Bh=function(a){if(this.a){this.T=a.coordinate;a.frameState=this.a;var b=this.j.a,c;if(!1!==this.b(a))for(c=b.length-1;0<=c;c--){var d=b[c];if(d.c()&&!d.handleEvent(a))break}}};k.Ml=function(){var a=this.a,b=this.Ha;if(b.b.length){var c=16,d=c;if(a){var e=a.viewHints;e[0]&&(c=this.yf?8:0,d=2);e[1]&&(c=this.zf?8:0,d=2)}b.j<c&&(Me(b),Oe(b,c,d))}b=this.Va;c=0;for(d=b.length;c<d;++c)b[c](this,a);b.length=0};k.Ol=function(){this.render()};
k.Ql=function(){var a;this.Wf()&&(a=this.vc());if(this.u){for(var b=0,c=this.u.length;b<c;++b)Bc(this.u[b]);this.u=null}a?(a.appendChild(this.c),a=this.na?this.na:a,this.u=[z(a,"keydown",this.pd,this),z(a,"keypress",this.pd,this)],this.i||(this.i=this.Cd.bind(this),window.addEventListener("resize",this.i,!1))):(jd(this.c),this.i&&(window.removeEventListener("resize",this.i,!1),this.i=void 0));this.Cd()};k.Rl=function(){this.render()};k.Eh=function(){this.render()};
k.Sl=function(){this.Z&&(Bc(this.Z),this.Z=null);this.I&&(Bc(this.I),this.I=null);var a=this.$();a&&(this.c.setAttribute("data-view",w(a)),this.Z=z(a,"propertychange",this.Eh,this),this.I=z(a,"change",this.Eh,this));this.render()};k.zl=function(){this.G&&(this.G.forEach(Bc),this.G=null);var a=this.Mc();a&&(this.G=[z(a,"propertychange",this.render,this),z(a,"change",this.render,this)]);this.render()};k.Jp=function(){this.f&&cancelAnimationFrame(this.f);this.fa()};
k.render=function(){void 0===this.f&&(this.f=requestAnimationFrame(this.fa))};k.Cp=function(a){return this.l.remove(a)};k.Dp=function(a){return this.j.remove(a)};k.Fp=function(a){return this.Mc().sd().remove(a)};k.Gp=function(a){return this.o.remove(a)};
k.Ip=function(a){var b,c,d=this.Nb(),e=this.$(),f=Ja(),g=null;if(void 0!==d&&0<d[0]&&0<d[1]&&e&&hg(e)){var g=ag(e,this.a?this.a.viewHints:void 0),h=this.Mc().Tf(),l={};b=0;for(c=h.length;b<c;++b)l[w(h[b].layer)]=h[b];b=e.V();g={animate:!1,attributions:{},coordinateToPixelTransform:this.Gb,extent:f,focus:this.T?this.T:b.center,index:this.le++,layerStates:l,layerStatesArray:h,logos:qb({},this.wf),pixelRatio:this.Ef,pixelToCoordinateTransform:this.Ff,postRenderFunctions:[],size:d,skippedFeatureUids:this.ea,
tileQueue:this.Ha,time:a,usedTiles:{},viewState:b,viewHints:g,wantedTiles:{}}}g&&(g.extent=lb(b.center,b.resolution,b.rotation,g.size,f));this.a=g;this.C.Dg(g);g&&(g.animate&&this.render(),Array.prototype.push.apply(this.Va,g.postRenderFunctions),g.viewHints[0]||g.viewHints[1]||$a(g.extent,this.yb)||(this.b(new Gd("moveend",this,g)),Oa(g.extent,this.yb)));this.b(new Gd("postrender",this,g));setTimeout(this.Ml.bind(this),0)};k.lj=function(a){this.set("layergroup",a)};
k.Ig=function(a){this.set("size",a)};k.Ke=function(a){this.set("target",a)};k.Yp=function(a){this.set("view",a)};k.tj=function(a){a=w(a).toString();this.ea[a]=!0;this.render()};k.Cd=function(){var a=this.vc();if(a){var b=getComputedStyle(a);this.Ig([a.offsetWidth-parseFloat(b.borderLeftWidth)-parseFloat(b.paddingLeft)-parseFloat(b.paddingRight)-parseFloat(b.borderRightWidth),a.offsetHeight-parseFloat(b.borderTopWidth)-parseFloat(b.paddingTop)-parseFloat(b.paddingBottom)-parseFloat(b.borderBottomWidth)])}else this.Ig(void 0)};
k.yj=function(a){a=w(a).toString();delete this.ea[a];this.render()};
function rk(a){var b=null;void 0!==a.keyboardEventTarget&&(b="string"===typeof a.keyboardEventTarget?document.getElementById(a.keyboardEventTarget):a.keyboardEventTarget);var c={},d={};if(void 0===a.logo||"boolean"===typeof a.logo&&a.logo)d["data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAAA3NCSVQICAjb4U/gAAAACXBIWXMAAAHGAAABxgEXwfpGAAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAAAhNQTFRF////AP//AICAgP//AFVVQECA////K1VVSbbbYL/fJ05idsTYJFtbbcjbJllmZszWWMTOIFhoHlNiZszTa9DdUcHNHlNlV8XRIVdiasrUHlZjIVZjaMnVH1RlIFRkH1RkH1ZlasvYasvXVsPQH1VkacnVa8vWIVZjIFRjVMPQa8rXIVVkXsXRsNveIFVkIFZlIVVj3eDeh6GmbMvXH1ZkIFRka8rWbMvXIFVkIFVjIFVkbMvWH1VjbMvWIFVlbcvWIFVla8vVIFVkbMvWbMvVH1VkbMvWIFVlbcvWIFVkbcvVbMvWjNPbIFVkU8LPwMzNIFVkbczWIFVkbsvWbMvXIFVkRnB8bcvW2+TkW8XRIFVkIlZlJVloJlpoKlxrLl9tMmJwOWd0Omh1RXF8TneCT3iDUHiDU8LPVMLPVcLPVcPQVsPPVsPQV8PQWMTQWsTQW8TQXMXSXsXRX4SNX8bSYMfTYcfTYsfTY8jUZcfSZsnUaIqTacrVasrVa8jTa8rWbI2VbMvWbcvWdJObdcvUdszUd8vVeJaee87Yfc3WgJyjhqGnitDYjaarldPZnrK2oNbborW5o9bbo9fbpLa6q9ndrL3ArtndscDDutzfu8fJwN7gwt7gxc/QyuHhy+HizeHi0NfX0+Pj19zb1+Tj2uXk29/e3uLg3+Lh3+bl4uXj4ufl4+fl5Ofl5ufl5ujm5+jmySDnBAAAAFp0Uk5TAAECAgMEBAYHCA0NDg4UGRogIiMmKSssLzU7PkJJT1JTVFliY2hrdHZ3foSFhYeJjY2QkpugqbG1tre5w8zQ09XY3uXn6+zx8vT09vf4+Pj5+fr6/P39/f3+gz7SsAAAAVVJREFUOMtjYKA7EBDnwCPLrObS1BRiLoJLnte6CQy8FLHLCzs2QUG4FjZ5GbcmBDDjxJBXDWxCBrb8aM4zbkIDzpLYnAcE9VXlJSWlZRU13koIeW57mGx5XjoMZEUqwxWYQaQbSzLSkYGfKFSe0QMsX5WbjgY0YS4MBplemI4BdGBW+DQ11eZiymfqQuXZIjqwyadPNoSZ4L+0FVM6e+oGI6g8a9iKNT3o8kVzNkzRg5lgl7p4wyRUL9Yt2jAxVh6mQCogae6GmflI8p0r13VFWTHBQ0rWPW7ahgWVcPm+9cuLoyy4kCJDzCm6d8PSFoh0zvQNC5OjDJhQopPPJqph1doJBUD5tnkbZiUEqaCnB3bTqLTFG1bPn71kw4b+GFdpLElKIzRxxgYgWNYc5SCENVHKeUaltHdXx0dZ8uBI1hJ2UUDgq82CM2MwKeibqAvSO7MCABq0wXEPiqWEAAAAAElFTkSuQmCC"]="https://openlayers.org/";
else{var e=a.logo;"string"===typeof e?d[e]="":e instanceof HTMLElement?d[w(e).toString()]=e:e&&(sa("string"==typeof e.href,44),sa("string"==typeof e.src,45),d[e.src]=e.href)}e=a.layers instanceof rh?a.layers:new rh({layers:a.layers});c.layergroup=e;c.target=a.target;c.view=void 0!==a.view?a.view:new G;var e=Jh,f;void 0!==a.renderer?(Array.isArray(a.renderer)?f=a.renderer:"string"===typeof a.renderer?f=[a.renderer]:sa(!1,46),0<=f.indexOf("dom")&&(f=f.concat(qk))):f=qk;var g,h;g=0;for(h=f.length;g<
h;++g){var l=f[g];if("canvas"==l){if(Vd){e=ei;break}}else if("webgl"==l&&Nd){e=mk;break}}void 0!==a.controls?Array.isArray(a.controls)?f=new D(a.controls.slice()):(sa(a.controls instanceof D,47),f=a.controls):f=vd();void 0!==a.interactions?Array.isArray(a.interactions)?g=new D(a.interactions.slice()):(sa(a.interactions instanceof D,48),g=a.interactions):g=oh();void 0!==a.overlays?Array.isArray(a.overlays)?a=new D(a.overlays.slice()):(sa(a.overlays instanceof D,49),a=a.overlays):a=new D;return{controls:f,
interactions:g,keyboardEventTarget:b,logos:d,overlays:a,Kp:e,values:c}};function sk(a){Qc.call(this);this.f=a.id;this.o=void 0!==a.insertFirst?a.insertFirst:!0;this.u=void 0!==a.stopEvent?a.stopEvent:!0;this.c=document.createElement("DIV");this.c.className="ol-overlay-container";this.c.style.position="absolute";this.autoPan=void 0!==a.autoPan?a.autoPan:!1;this.j=a.autoPanAnimation||{};this.l=void 0!==a.autoPanMargin?a.autoPanMargin:20;this.a={re:"",He:"",lf:"",uf:"",visible:!0};this.i=null;z(this,Sc(tk),this.ul,this);z(this,Sc(uk),this.El,this);z(this,Sc(vk),this.Il,
this);z(this,Sc(wk),this.Kl,this);z(this,Sc(xk),this.Ll,this);void 0!==a.element&&this.gj(a.element);this.nj(void 0!==a.offset?a.offset:[0,0]);this.qj(void 0!==a.positioning?a.positioning:"top-left");void 0!==a.position&&this.Me(a.position)}u(sk,Qc);k=sk.prototype;k.Rd=function(){return this.get(tk)};k.Fm=function(){return this.f};k.Le=function(){return this.get(uk)};k.wh=function(){return this.get(vk)};k.Rh=function(){return this.get(wk)};k.xh=function(){return this.get(xk)};
k.ul=function(){for(var a=this.c;a.lastChild;)a.removeChild(a.lastChild);(a=this.Rd())&&this.c.appendChild(a)};k.El=function(){this.i&&(jd(this.c),Bc(this.i),this.i=null);var a=this.Le();a&&(this.i=z(a,"postrender",this.render,this),yk(this),a=this.u?a.v:a.A,this.o?a.insertBefore(this.c,a.childNodes[0]||null):a.appendChild(this.c))};k.render=function(){yk(this)};k.Il=function(){yk(this)};
k.Kl=function(){yk(this);if(this.get(wk)&&this.autoPan){var a=this.Le();if(a&&a.vc()){var b=zk(a.vc(),a.Nb()),c=this.Rd(),d=c.offsetWidth,e=getComputedStyle(c),d=d+(parseInt(e.marginLeft,10)+parseInt(e.marginRight,10)),e=c.offsetHeight,f=getComputedStyle(c),e=e+(parseInt(f.marginTop,10)+parseInt(f.marginBottom,10)),g=zk(c,[d,e]),c=this.l;Ua(b,g)||(d=g[0]-b[0],e=b[2]-g[2],f=g[1]-b[1],g=b[3]-g[3],b=[0,0],0>d?b[0]=d-c:0>e&&(b[0]=Math.abs(e)+c),0>f?b[1]=f-c:0>g&&(b[1]=Math.abs(g)+c),0===b[0]&&0===b[1])||
(c=a.$().za(),c=a.Ka(c),b=[c[0]+b[0],c[1]+b[1]],a.$().animate({center:a.Xa(b),duration:this.j.duration,easing:this.j.easing}))}}};k.Ll=function(){yk(this)};k.gj=function(a){this.set(tk,a)};k.setMap=function(a){this.set(uk,a)};k.nj=function(a){this.set(vk,a)};k.Me=function(a){this.set(wk,a)};function zk(a,b){var c=a.getBoundingClientRect(),d=c.left+window.pageXOffset,c=c.top+window.pageYOffset;return[d,c,d+b[0],c+b[1]]}k.qj=function(a){this.set(xk,a)};
function Ak(a,b){a.a.visible!==b&&(a.c.style.display=b?"":"none",a.a.visible=b)}
function yk(a){var b=a.Le(),c=a.Rh();if(b&&b.a&&c){var c=b.Ka(c),d=b.Nb(),b=a.c.style,e=a.wh(),f=a.xh();Ak(a,!0);var g=e[0],e=e[1];if("bottom-right"==f||"center-right"==f||"top-right"==f)""!==a.a.He&&(a.a.He=b.left=""),g=Math.round(d[0]-c[0]-g)+"px",a.a.lf!=g&&(a.a.lf=b.right=g);else{""!==a.a.lf&&(a.a.lf=b.right="");if("bottom-center"==f||"center-center"==f||"top-center"==f)g-=a.c.offsetWidth/2;g=Math.round(c[0]+g)+"px";a.a.He!=g&&(a.a.He=b.left=g)}if("bottom-left"==f||"bottom-center"==f||"bottom-right"==
f)""!==a.a.uf&&(a.a.uf=b.top=""),c=Math.round(d[1]-c[1]-e)+"px",a.a.re!=c&&(a.a.re=b.bottom=c);else{""!==a.a.re&&(a.a.re=b.bottom="");if("center-left"==f||"center-center"==f||"center-right"==f)e-=a.c.offsetHeight/2;c=Math.round(c[1]+e)+"px";a.a.uf!=c&&(a.a.uf=b.top=c)}}else Ak(a,!1)}var tk="element",uk="map",vk="offset",wk="position",xk="positioning";function Bk(a){function b(a){a=h.Of(a);l.a.$().lb(a);window.removeEventListener("mousemove",c);window.removeEventListener("mouseup",b)}function c(a){a=h.Of({clientX:a.clientX-n.offsetWidth/2,clientY:a.clientY+n.offsetHeight/2});m.Me(a)}a=a?a:{};this.j=void 0!==a.collapsed?a.collapsed:!0;this.l=void 0!==a.collapsible?a.collapsible:!0;this.l||(this.j=!1);var d=void 0!==a.className?a.className:"ol-overviewmap",e=void 0!==a.tipLabel?a.tipLabel:"Overview map",f=void 0!==a.collapseLabel?a.collapseLabel:
"\u00ab";"string"===typeof f?(this.v=document.createElement("span"),this.v.textContent=f):this.v=f;f=void 0!==a.label?a.label:"\u00bb";"string"===typeof f?(this.A=document.createElement("span"),this.A.textContent=f):this.A=f;var g=this.l&&!this.j?this.v:this.A,f=document.createElement("button");f.setAttribute("type","button");f.title=e;f.appendChild(g);z(f,"click",this.Vm,this);this.C=document.createElement("DIV");this.C.className="ol-overviewmap-map";var h=this.c=new H({controls:new D,interactions:new D,
view:a.view});a.layers&&a.layers.forEach(function(a){h.$g(a)},this);e=document.createElement("DIV");e.className="ol-overviewmap-box";e.style.boxSizing="border-box";this.o=new sk({position:[0,0],positioning:"bottom-left",element:e});this.c.ah(this.o);e=document.createElement("div");e.className=d+" ol-unselectable ol-control"+(this.j&&this.l?" ol-collapsed":"")+(this.l?"":" ol-uncollapsible");e.appendChild(this.C);e.appendChild(f);kd.call(this,{element:e,render:a.render?a.render:Ck,target:a.target});
var l=this,m=this.o,n=this.o.Rd();n.addEventListener("mousedown",function(){window.addEventListener("mousemove",c);window.addEventListener("mouseup",b)})}u(Bk,kd);k=Bk.prototype;k.setMap=function(a){var b=this.a;a!==b&&(b&&((b=b.$())&&Hc(b,Sc("rotation"),this.Fe,this),this.c.Ke(null)),kd.prototype.setMap.call(this,a),a&&(this.c.Ke(this.C),this.u.push(z(a,"propertychange",this.Fl,this)),this.c.Qh().fc()||this.c.lj(a.Mc()),a=a.$()))&&(z(a,Sc("rotation"),this.Fe,this),hg(a)&&(this.c.Cd(),Dk(this)))};
k.Fl=function(a){"view"===a.key&&((a=a.oldValue)&&Hc(a,Sc("rotation"),this.Fe,this),a=this.a.$(),z(a,Sc("rotation"),this.Fe,this))};k.Fe=function(){this.c.$().Ne(this.a.$().Sa())};function Ck(){var a=this.a,b=this.c;if(a.a&&b.a){var c=a.Nb(),a=a.$().hd(c),d=b.Nb(),c=b.$().hd(d),e=b.Ka(fb(a)),f=b.Ka(db(a)),b=Math.abs(e[0]-f[0]),e=Math.abs(e[1]-f[1]),f=d[0],d=d[1];b<.1*f||e<.1*d||b>.75*f||e>.75*d?Dk(this):Ua(c,a)||(a=this.c,c=this.a.$(),a.$().lb(c.za()))}Ek(this)}
function Dk(a){var b=a.a;a=a.c;var c=b.Nb(),b=b.$().hd(c);a=a.$();ob(b,1/(.1*Math.pow(2,Math.log(7.5)/Math.LN2/2)));a.Mf(b)}function Ek(a){var b=a.a,c=a.c;if(b.a&&c.a){var d=b.Nb(),e=b.$(),f=c.$(),c=e.Sa(),b=a.o,g=a.o.Rd(),h=e.hd(d),d=f.Ra(),e=cb(h),f=eb(h),l;if(a=a.a.$().za())l=[e[0]-a[0],e[1]-a[1]],cf(l,c),Xe(l,a);b.Me(l);g&&(g.style.width=Math.abs((e[0]-f[0])/d)+"px",g.style.height=Math.abs((f[1]-e[1])/d)+"px")}}k.Vm=function(a){a.preventDefault();Fk(this)};
function Fk(a){a.element.classList.toggle("ol-collapsed");a.j?id(a.v,a.A):id(a.A,a.v);a.j=!a.j;var b=a.c;a.j||b.a||(b.Cd(),Dk(a),Gc(b,"postrender",function(){Ek(this)},a))}k.Um=function(){return this.l};k.Xm=function(a){this.l!==a&&(this.l=a,this.element.classList.toggle("ol-uncollapsible"),!a&&this.j&&Fk(this))};k.Wm=function(a){this.l&&this.j!==a&&Fk(this)};k.Tm=function(){return this.j};k.bl=function(){return this.c};function Gk(a){a=a?a:{};var b=void 0!==a.className?a.className:"ol-scale-line";this.l=document.createElement("DIV");this.l.className=b+"-inner";this.c=document.createElement("DIV");this.c.className=b+" ol-unselectable";this.c.appendChild(this.l);this.v=null;this.o=void 0!==a.minWidth?a.minWidth:64;this.j=!1;this.C=void 0;this.A="";kd.call(this,{element:this.c,render:a.render?a.render:Hk,target:a.target});z(this,Sc(Ik),this.I,this);this.G(a.units||"metric")}u(Gk,kd);var Jk=[1,2,5];
Gk.prototype.Kb=function(){return this.get(Ik)};function Hk(a){(a=a.frameState)?this.v=a.viewState:this.v=null;Kk(this)}Gk.prototype.I=function(){Kk(this)};Gk.prototype.G=function(a){this.set(Ik,a)};
function Kk(a){var b=a.v;if(b){var c=b.projection,d=c.uc(),b=Rb(c,b.resolution,b.center)*d,d=a.o*b,c="",e=a.Kb();"degrees"==e?(c=xb.degrees,b/=c,d<c/60?(c="\u2033",b*=3600):d<c?(c="\u2032",b*=60):c="\u00b0"):"imperial"==e?.9144>d?(c="in",b/=.0254):1609.344>d?(c="ft",b/=.3048):(c="mi",b/=1609.344):"nautical"==e?(b/=1852,c="nm"):"metric"==e?.001>d?(c="\u03bcm",b*=1E6):1>d?(c="mm",b*=1E3):1E3>d?c="m":(c="km",b/=1E3):"us"==e?.9144>d?(c="in",b*=39.37):1609.344>d?(c="ft",b/=.30480061):(c="mi",b/=1609.3472):
sa(!1,33);for(var e=3*Math.floor(Math.log(a.o*b)/Math.log(10)),f;;){f=Jk[(e%3+3)%3]*Math.pow(10,Math.floor(e/3));d=Math.round(f/b);if(isNaN(d)){a.c.style.display="none";a.j=!1;return}if(d>=a.o)break;++e}b=f+" "+c;a.A!=b&&(a.l.innerHTML=b,a.A=b);a.C!=d&&(a.l.style.width=d+"px",a.C=d);a.j||(a.c.style.display="",a.j=!0)}else a.j&&(a.c.style.display="none",a.j=!1)}var Ik="units";function Lk(a){a=a?a:{};this.c=void 0;this.j=Mk;this.A=this.o=0;this.I=null;this.ea=!1;this.T=void 0!==a.duration?a.duration:200;var b=void 0!==a.className?a.className:"ol-zoomslider",c=document.createElement("button");c.setAttribute("type","button");c.className=b+"-thumb ol-unselectable";var d=document.createElement("div");d.className=b+" ol-unselectable ol-control";d.appendChild(c);this.l=new Ae(d);z(this.l,"pointerdown",this.tl,this);z(this.l,"pointermove",this.rl,this);z(this.l,"pointerup",this.sl,
this);z(d,"click",this.ql,this);z(c,"click",Mc);kd.call(this,{element:d,render:a.render?a.render:Nk})}u(Lk,kd);Lk.prototype.ra=function(){Kc(this.l);kd.prototype.ra.call(this)};var Mk=0;k=Lk.prototype;k.setMap=function(a){kd.prototype.setMap.call(this,a);a&&a.render()};
function Nk(a){if(a.frameState){if(!this.ea){var b=this.element,c=b.offsetWidth,d=b.offsetHeight,e=b.firstElementChild,f=getComputedStyle(e),b=e.offsetWidth+parseFloat(f.marginRight)+parseFloat(f.marginLeft),e=e.offsetHeight+parseFloat(f.marginTop)+parseFloat(f.marginBottom);this.I=[b,e];c>d?(this.j=1,this.A=c-b):(this.j=Mk,this.o=d-e);this.ea=!0}a=a.frameState.viewState.resolution;a!==this.c&&(this.c=a,Ok(this,a))}}
k.ql=function(a){var b=this.a.$();a=Pk(this,xa(1===this.j?(a.offsetX-this.I[0]/2)/this.A:(a.offsetY-this.I[1]/2)/this.o,0,1));b.animate({resolution:b.constrainResolution(a),duration:this.T,easing:pd})};k.tl=function(a){this.v||a.b.target!==this.element.firstElementChild||($f(this.a.$(),1,1),this.C=a.clientX,this.G=a.clientY,this.v=!0)};
k.rl=function(a){if(this.v){var b=this.element.firstElementChild;this.c=Pk(this,xa(1===this.j?(a.clientX-this.C+parseInt(b.style.left,10))/this.A:(a.clientY-this.G+parseInt(b.style.top,10))/this.o,0,1));this.a.$().$c(this.c);Ok(this,this.c);this.C=a.clientX;this.G=a.clientY}};k.sl=function(){if(this.v){var a=this.a.$();$f(a,1,-1);a.animate({resolution:a.constrainResolution(this.c),duration:this.T,easing:pd});this.v=!1;this.G=this.C=void 0}};
function Ok(a,b){var c;c=1-gg(a.a.$())(b);var d=a.element.firstElementChild;1==a.j?d.style.left=a.A*c+"px":d.style.top=a.o*c+"px"}function Pk(a,b){return fg(a.a.$())(1-b)};function Qk(a){a=a?a:{};this.c=a.extent?a.extent:null;var b=void 0!==a.className?a.className:"ol-zoom-extent",c=void 0!==a.label?a.label:"E",d=void 0!==a.tipLabel?a.tipLabel:"Fit to extent",e=document.createElement("button");e.setAttribute("type","button");e.title=d;e.appendChild("string"===typeof c?document.createTextNode(c):c);z(e,"click",this.j,this);c=document.createElement("div");c.className=b+" ol-unselectable ol-control";c.appendChild(e);kd.call(this,{element:c,target:a.target})}u(Qk,kd);
Qk.prototype.j=function(a){a.preventDefault();a=this.a.$();var b=this.c?this.c:a.o.D();a.Mf(b)};function Rk(a){Qc.call(this);a=a?a:{};this.a=null;z(this,Sc(Sk),this.rm,this);this.bg(void 0!==a.tracking?a.tracking:!1)}u(Rk,Qc);k=Rk.prototype;k.ra=function(){this.bg(!1);Qc.prototype.ra.call(this)};
k.Ro=function(a){if(null!==a.alpha){var b=Ca(a.alpha);this.set(Tk,b);"boolean"===typeof a.absolute&&a.absolute?this.set(Uk,b):"number"===typeof a.webkitCompassHeading&&-1!=a.webkitCompassAccuracy&&this.set(Uk,Ca(a.webkitCompassHeading))}null!==a.beta&&this.set(Vk,Ca(a.beta));null!==a.gamma&&this.set(Wk,Ca(a.gamma));this.s()};k.Bk=function(){return this.get(Tk)};k.Ek=function(){return this.get(Vk)};k.Kk=function(){return this.get(Wk)};k.qm=function(){return this.get(Uk)};k.Mh=function(){return this.get(Sk)};
k.rm=function(){if(Wd){var a=this.Mh();a&&!this.a?this.a=z(window,"deviceorientation",this.Ro,this):a||null===this.a||(Bc(this.a),this.a=null)}};k.bg=function(a){this.set(Sk,a)};var Tk="alpha",Vk="beta",Wk="gamma",Uk="heading",Sk="tracking";function Xk(a){this.f=a.opacity;this.o=a.rotateWithView;this.j=a.rotation;this.c=a.scale;this.u=a.snapToPixel}k=Xk.prototype;k.Ye=function(){return this.f};k.Ze=function(){return this.o};k.$e=function(){return this.j};k.af=function(){return this.c};k.ze=function(){return this.u};k.vd=function(a){this.f=a};k.bf=function(a){this.j=a};k.wd=function(a){this.c=a};function Yk(a){this.A=this.v=this.i=null;this.Wa=void 0!==a.fill?a.fill:null;this.qa=[0,0];this.b=a.points;this.a=void 0!==a.radius?a.radius:a.radius1;this.g=void 0!==a.radius2?a.radius2:this.a;this.l=void 0!==a.angle?a.angle:0;this.Za=void 0!==a.stroke?a.stroke:null;this.G=this.ta=this.C=null;this.O=a.atlasManager;Zk(this,this.O);Xk.call(this,{opacity:1,rotateWithView:void 0!==a.rotateWithView?a.rotateWithView:!1,rotation:void 0!==a.rotation?a.rotation:0,scale:1,snapToPixel:void 0!==a.snapToPixel?
a.snapToPixel:!0})}u(Yk,Xk);k=Yk.prototype;k.clone=function(){var a=new Yk({fill:this.Ca()?this.Ca().clone():void 0,points:this.g!==this.a?this.b/2:this.b,radius:this.a,radius2:this.g,angle:this.l,snapToPixel:this.u,stroke:this.Da()?this.Da().clone():void 0,rotation:this.j,rotateWithView:this.o,atlasManager:this.O});a.vd(this.f);a.wd(this.c);return a};k.Jc=function(){return this.C};k.Ji=function(){return this.l};k.Ca=function(){return this.Wa};k.kg=function(){return this.A};k.Y=function(){return this.v};
k.ye=function(){return this.G};k.Xe=function(){return 2};k.Tc=function(){return this.qa};k.Ki=function(){return this.b};k.Li=function(){return this.a};k.yh=function(){return this.g};k.kc=function(){return this.ta};k.Da=function(){return this.Za};k.Gh=function(){};k.load=function(){};k.xj=function(){};
function Zk(a,b){var c,d="",e="",f=0,g=null,h,l=0;a.Za&&(h=a.Za.a,null===h&&(h=Rh),h=fd(h),l=a.Za.c,void 0===l&&(l=1),g=a.Za.g,Ud||(g=null),e=a.Za.j,void 0===e&&(e="round"),d=a.Za.i,void 0===d&&(d="round"),f=a.Za.l,void 0===f&&(f=10));var m=2*(a.a+l)+1,d={strokeStyle:h,vj:l,size:m,lineCap:d,lineDash:g,lineJoin:e,miterLimit:f};void 0===b?(e=hd(m,m),a.v=e.canvas,c=m=a.v.width,a.jh(d,e,0,0),a.Wa?a.A=a.v:(e=hd(d.size,d.size),a.A=e.canvas,a.ih(d,e,0,0))):(m=Math.round(m),(e=!a.Wa)&&(c=a.ih.bind(a,d)),
a.Za?(f=a.Za,void 0===f.b&&(f.b="s",f.b=f.a?"string"===typeof f.a?f.b+f.a:f.b+w(f.a).toString():f.b+"-",f.b+=","+(void 0!==f.i?f.i.toString():"-")+","+(f.g?f.g.toString():"-")+","+(void 0!==f.f?f.f:"-")+","+(void 0!==f.j?f.j:"-")+","+(void 0!==f.l?f.l.toString():"-")+","+(void 0!==f.c?f.c.toString():"-")),f=f.b):f="-",a.Wa?(g=a.Wa,void 0===g.a&&(g.a=g.b instanceof CanvasPattern||g.b instanceof CanvasGradient?w(g.b).toString():"f"+(g.b?dd(g.b):"-")),g=g.a):g="-",a.i&&f==a.i[1]&&g==a.i[2]&&a.a==a.i[3]&&
a.g==a.i[4]&&a.l==a.i[5]&&a.b==a.i[6]||(a.i=["r"+f+g+(void 0!==a.a?a.a.toString():"-")+(void 0!==a.g?a.g.toString():"-")+(void 0!==a.l?a.l.toString():"-")+(void 0!==a.b?a.b.toString():"-"),f,g,a.a,a.g,a.l,a.b]),d=b.add(a.i[0],m,m,a.jh.bind(a,d),c),a.v=d.image,a.qa=[d.offsetX,d.offsetY],c=d.image.width,a.A=e?d.Ul:a.v);a.C=[m/2,m/2];a.ta=[m,m];a.G=[c,c]}
k.jh=function(a,b,c,d){var e;b.setTransform(1,0,0,1,0,0);b.translate(c,d);b.beginPath();if(Infinity===this.b)b.arc(a.size/2,a.size/2,this.a,0,2*Math.PI,!0);else for(this.g!==this.a&&(this.b*=2),c=0;c<=this.b;c++)d=2*c*Math.PI/this.b-Math.PI/2+this.l,e=c%2?this.g:this.a,b.lineTo(a.size/2+e*Math.cos(d),a.size/2+e*Math.sin(d));this.Wa&&(c=this.Wa.b,null===c&&(c=Ph),b.fillStyle=fd(c),b.fill());this.Za&&(b.strokeStyle=a.strokeStyle,b.lineWidth=a.vj,a.lineDash&&b.setLineDash(a.lineDash),b.lineCap=a.lineCap,
b.lineJoin=a.lineJoin,b.miterLimit=a.miterLimit,b.stroke());b.closePath()};
k.ih=function(a,b,c,d){b.setTransform(1,0,0,1,0,0);b.translate(c,d);b.beginPath();if(Infinity===this.b)b.arc(a.size/2,a.size/2,this.a,0,2*Math.PI,!0);else{this.g!==this.a&&(this.b*=2);var e;for(c=0;c<=this.b;c++)e=2*c*Math.PI/this.b-Math.PI/2+this.l,d=c%2?this.g:this.a,b.lineTo(a.size/2+d*Math.cos(e),a.size/2+d*Math.sin(e))}b.fillStyle=Ph;b.fill();this.Za&&(b.strokeStyle=a.strokeStyle,b.lineWidth=a.vj,a.lineDash&&b.setLineDash(a.lineDash),b.stroke());b.closePath()};function $k(a){a=a||{};Yk.call(this,{points:Infinity,fill:a.fill,radius:a.radius,snapToPixel:a.snapToPixel,stroke:a.stroke,atlasManager:a.atlasManager})}u($k,Yk);$k.prototype.clone=function(){var a=new $k({fill:this.Ca()?this.Ca().clone():void 0,stroke:this.Da()?this.Da().clone():void 0,radius:this.a,snapToPixel:this.u,atlasManager:this.O});a.vd(this.f);a.wd(this.c);return a};$k.prototype.Zc=function(a){this.a=a;Zk(this,this.O)};function al(a){a=a||{};this.b=void 0!==a.color?a.color:null;this.a=void 0}al.prototype.clone=function(){var a=this.b;return new al({color:a&&a.slice?a.slice():a||void 0})};al.prototype.g=function(){return this.b};al.prototype.c=function(a){this.b=a;this.a=void 0};function bl(a){a=a||{};this.Ic=null;this.Qa=cl;void 0!==a.geometry&&this.Ta(a.geometry);this.Wa=void 0!==a.fill?a.fill:null;this.N=void 0!==a.image?a.image:null;this.Za=void 0!==a.stroke?a.stroke:null;this.Fa=void 0!==a.text?a.text:null;this.Bj=a.zIndex}k=bl.prototype;
k.clone=function(){var a=this.U();a&&a.clone&&(a=a.clone());return new bl({geometry:a,fill:this.Ca()?this.Ca().clone():void 0,image:this.Y()?this.Y().clone():void 0,stroke:this.Da()?this.Da().clone():void 0,text:this.Oa()?this.Oa().clone():void 0,zIndex:this.Aa()})};k.U=function(){return this.Ic};k.Lk=function(){return this.Qa};k.Ca=function(){return this.Wa};k.mf=function(a){this.Wa=a};k.Y=function(){return this.N};k.Hg=function(a){this.N=a};k.Da=function(){return this.Za};
k.nf=function(a){this.Za=a};k.Oa=function(){return this.Fa};k.pf=function(a){this.Fa=a};k.Aa=function(){return this.Bj};k.Ta=function(a){"function"===typeof a?this.Qa=a:"string"===typeof a?this.Qa=function(b){return b.get(a)}:a?a&&(this.Qa=function(){return a}):this.Qa=cl;this.Ic=a};k.Xb=function(a){this.Bj=a};function dl(a){if("function"!==typeof a){var b;Array.isArray(a)?b=a:(sa(a instanceof bl,41),b=[a]);a=function(){return b}}return a}var el=null;
function fl(){if(!el){var a=new al({color:"rgba(255,255,255,0.4)"}),b=new tj({color:"#3399CC",width:1.25});el=[new bl({image:new $k({fill:a,stroke:b,radius:5}),fill:a,stroke:b})]}return el}
function gl(){var a={},b=[255,255,255,1],c=[0,153,255,1];a.Polygon=[new bl({fill:new al({color:[255,255,255,.5]})})];a.MultiPolygon=a.Polygon;a.LineString=[new bl({stroke:new tj({color:b,width:5})}),new bl({stroke:new tj({color:c,width:3})})];a.MultiLineString=a.LineString;a.Circle=a.Polygon.concat(a.LineString);a.Point=[new bl({image:new $k({radius:6,fill:new al({color:c}),stroke:new tj({color:b,width:1.5})}),zIndex:Infinity})];a.MultiPoint=a.Point;a.GeometryCollection=a.Polygon.concat(a.LineString,
a.Point);return a}function cl(a){return a.U()};function I(a){Qc.call(this);this.a=void 0;this.c="geometry";this.f=null;this.j=void 0;this.i=null;z(this,Sc(this.c),this.De,this);void 0!==a&&(a instanceof lf||!a?this.Ta(a):this.H(a))}u(I,Qc);k=I.prototype;k.clone=function(){var a=new I(this.M());a.Yc(this.c);var b=this.U();b&&a.Ta(b.clone());(b=this.f)&&a.cg(b);return a};k.U=function(){return this.get(this.c)};k.sm=function(){return this.a};k.Mk=function(){return this.c};k.tm=function(){return this.f};k.Rc=function(){return this.j};k.vl=function(){this.s()};
k.De=function(){this.i&&(Bc(this.i),this.i=null);var a=this.U();a&&(this.i=z(a,"change",this.vl,this));this.s()};k.Ta=function(a){this.set(this.c,a)};k.cg=function(a){this.j=(this.f=a)?hl(a):void 0;this.s()};k.lc=function(a){this.a=a;this.s()};k.Yc=function(a){Hc(this,Sc(this.c),this.De,this);this.c=a;z(this,Sc(this.c),this.De,this);this.De()};
function hl(a){var b;if("function"===typeof a)2==a.length?b=function(b){return a(this,b)}:b=a;else{var c;Array.isArray(a)?c=a:(sa(a instanceof bl,41),c=[a]);b=function(){return c}}return b};var il=document.implementation.createDocument("","",null);function kl(a,b){return il.createElementNS(a,b)}function ll(a,b){return ml(a,b,[]).join("")}function ml(a,b,c){if(a.nodeType==Node.CDATA_SECTION_NODE||a.nodeType==Node.TEXT_NODE)b?c.push(String(a.nodeValue).replace(/(\r\n|\r|\n)/g,"")):c.push(a.nodeValue);else for(a=a.firstChild;a;a=a.nextSibling)ml(a,b,c);return c}function nl(a){return a instanceof Document}function pl(a){return a instanceof Node}
function ql(a){return(new DOMParser).parseFromString(a,"application/xml")}function rl(a,b){return function(c,d){var e=a.call(b,c,d);void 0!==e&&ha(d[d.length-1],e)}}function sl(a,b){return function(c,d){var e=a.call(void 0!==b?b:this,c,d);void 0!==e&&d[d.length-1].push(e)}}function tl(a,b){return function(c,d){var e=a.call(void 0!==b?b:this,c,d);void 0!==e&&(d[d.length-1]=e)}}
function ul(a){return function(b,c){var d=a.call(this,b,c);if(void 0!==d){var e=c[c.length-1],f=b.localName,g;f in e?g=e[f]:g=e[f]=[];g.push(d)}}}function J(a,b){return function(c,d){var e=a.call(this,c,d);void 0!==e&&(d[d.length-1][void 0!==b?b:c.localName]=e)}}function K(a,b){return function(c,d,e){a.call(void 0!==b?b:this,c,d,e);e[e.length-1].node.appendChild(c)}}
function vl(a){var b,c;return function(d,e,f){if(!b){b={};var g={};g[d.localName]=a;b[d.namespaceURI]=g;c=wl(d.localName)}xl(b,c,e,f)}}function wl(a,b){return function(c,d,e){c=d[d.length-1].node;d=a;void 0===d&&(d=e);e=b;void 0===b&&(e=c.namespaceURI);return kl(e,d)}}var yl=wl();function zl(a,b){for(var c=b.length,d=Array(c),e=0;e<c;++e)d[e]=a[b[e]];return d}function L(a,b,c){c=void 0!==c?c:{};var d,e;d=0;for(e=a.length;d<e;++d)c[a[d]]=b;return c}
function Al(a,b,c,d){for(b=b.firstElementChild;b;b=b.nextElementSibling){var e=a[b.namespaceURI];void 0!==e&&(e=e[b.localName])&&e.call(d,b,c)}}function M(a,b,c,d,e){d.push(a);Al(b,c,d,e);return d.pop()}function xl(a,b,c,d,e,f){for(var g=(void 0!==e?e:c).length,h,l,m=0;m<g;++m)h=c[m],void 0!==h&&(l=b.call(f,h,d,void 0!==e?e[m]:void 0),void 0!==l&&a[l.namespaceURI][l.localName].call(f,l,h,d))}function Bl(a,b,c,d,e,f,g){e.push(a);xl(b,c,d,e,f,g);e.pop()};function Cl(a,b,c,d){return function(e,f,g){var h=new XMLHttpRequest;h.open("GET","function"===typeof a?a(e,f,g):a,!0);"arraybuffer"==b.S()&&(h.responseType="arraybuffer");h.onload=function(){if(!h.status||200<=h.status&&300>h.status){var a=b.S(),e;"json"==a||"text"==a?e=h.responseText:"xml"==a?(e=h.responseXML)||(e=ql(h.responseText)):"arraybuffer"==a&&(e=h.response);e?c.call(this,b.Pa(e,{featureProjection:g}),b.jb(e)):d.call(this)}else d.call(this)}.bind(this);h.onerror=function(){d.call(this)}.bind(this);
h.send()}}function Dl(a,b){return Cl(a,b,function(a){this.gd(a)},oa)};function El(){this.i=this.defaultDataProjection=null}function Fl(a,b,c){var d;c&&(d={dataProjection:c.dataProjection?c.dataProjection:a.jb(b),featureProjection:c.featureProjection});return Gl(a,d)}function Gl(a,b){return qb({dataProjection:a.defaultDataProjection,featureProjection:a.i},b)}
function Hl(a,b,c){var d=c?Tb(c.featureProjection):null,e=c?Tb(c.dataProjection):null,f;d&&e&&!bc(d,e)?a instanceof lf?f=(b?a.clone():a).tb(b?d:e,b?e:d):f=gc(b?a.slice():a,b?d:e,b?e:d):f=a;if(b&&c&&c.decimals){var g=Math.pow(10,c.decimals);a=function(a){for(var b=0,c=a.length;b<c;++b)a[b]=Math.round(a[b]*g)/g;return a};Array.isArray(f)?a(f):f.Fc(a)}return f};function Il(){El.call(this)}u(Il,El);function Jl(a){return"string"===typeof a?(a=JSON.parse(a))?a:null:null!==a?a:null}k=Il.prototype;k.S=function(){return"json"};k.Vb=function(a,b){return this.Wc(Jl(a),Fl(this,a,b))};k.Pa=function(a,b){return this.sg(Jl(a),Fl(this,a,b))};k.Xc=function(a,b){return this.wg(Jl(a),Fl(this,a,b))};k.jb=function(a){return this.zg(Jl(a))};k.Dd=function(a,b){return JSON.stringify(this.dd(a,b))};k.Yb=function(a,b){return JSON.stringify(this.ge(a,b))};
k.ed=function(a,b){return JSON.stringify(this.ie(a,b))};function Kl(a,b,c,d,e,f){var g=NaN,h=NaN,l=(c-b)/d;if(1===l)g=a[b],h=a[b+1];else if(2==l)g=(1-e)*a[b]+e*a[b+d],h=(1-e)*a[b+1]+e*a[b+d+1];else if(l){var h=a[b],l=a[b+1],m=0,g=[0],n;for(n=b+d;n<c;n+=d){var p=a[n],q=a[n+1],m=m+Math.sqrt((p-h)*(p-h)+(q-l)*(q-l));g.push(m);h=p;l=q}c=e*m;l=0;m=g.length;for(n=!1;l<m;)e=l+(m-l>>1),h=+ea(g[e],c),0>h?l=e+1:(m=e,n=!h);e=n?l:~l;0>e?(c=(c-g[-e-2])/(g[-e-1]-g[-e-2]),b+=(-e-2)*d,g=Ea(a[b],a[b+d],c),h=Ea(a[b+1],a[b+d+1],c)):(g=a[b+e*d],h=a[b+e*d+1])}return f?(f[0]=
g,f[1]=h,f):[g,h]}function Ll(a,b,c,d,e,f){if(c==b)return null;if(e<a[b+d-1])return f?(c=a.slice(b,b+d),c[d-1]=e,c):null;if(a[c-1]<e)return f?(c=a.slice(c-d,c),c[d-1]=e,c):null;if(e==a[b+d-1])return a.slice(b,b+d);b/=d;for(c/=d;b<c;)f=b+c>>1,e<a[(f+1)*d-1]?c=f:b=f+1;c=a[b*d-1];if(e==c)return a.slice((b-1)*d,(b-1)*d+d);f=(e-c)/(a[(b+1)*d-1]-c);c=[];var g;for(g=0;g<d-1;++g)c.push(Ea(a[(b-1)*d+g],a[b*d+g],f));c.push(e);return c}
function Ml(a,b,c,d,e,f){var g=0;if(f)return Ll(a,g,b[b.length-1],c,d,e);if(d<a[c-1])return e?(a=a.slice(0,c),a[c-1]=d,a):null;if(a[a.length-1]<d)return e?(a=a.slice(a.length-c),a[c-1]=d,a):null;e=0;for(f=b.length;e<f;++e){var h=b[e];if(g!=h){if(d<a[g+c-1])break;else if(d<=a[h-1])return Ll(a,g,h,c,d,!1);g=h}}return null};function N(a,b){of.call(this);this.c=null;this.v=this.A=this.j=-1;this.pa(a,b)}u(N,of);k=N.prototype;k.ik=function(a){this.B?ha(this.B,a):this.B=a.slice();this.s()};k.clone=function(){var a=new N(null);a.ca(this.la,this.B.slice());return a};k.Hb=function(a,b,c,d){if(d<Pa(this.D(),a,b))return d;this.v!=this.g&&(this.A=Math.sqrt(vf(this.B,0,this.B.length,this.a,0)),this.v=this.g);return xf(this.B,0,this.B.length,this.a,this.A,!1,a,b,c,d)};
k.yk=function(a,b){return Mf(this.B,0,this.B.length,this.a,a,b)};k.gn=function(a,b){return"XYM"!=this.la&&"XYZM"!=this.la?null:Ll(this.B,0,this.B.length,this.a,a,void 0!==b?b:!1)};k.W=function(){return Cf(this.B,0,this.B.length,this.a)};k.ph=function(a,b){return Kl(this.B,0,this.B.length,this.a,a,b)};k.hn=function(){var a=this.B,b=this.a,c=a[0],d=a[1],e=0,f;for(f=0+b;f<this.B.length;f+=b)var g=a[f],h=a[f+1],e=e+Math.sqrt((g-c)*(g-c)+(h-d)*(h-d)),c=g,d=h;return e};
function ai(a){a.j!=a.g&&(a.c=a.ph(.5,a.c),a.j=a.g);return a.c}k.od=function(a){var b=[];b.length=Ef(this.B,0,this.B.length,this.a,a,b,0);a=new N(null);a.ca("XY",b);return a};k.S=function(){return"LineString"};k.Ya=function(a){return Nf(this.B,0,this.B.length,this.a,a)};k.pa=function(a,b){a?(rf(this,b,a,1),this.B||(this.B=[]),this.B.length=Af(this.B,0,a,this.a),this.s()):this.ca("XY",null)};k.ca=function(a,b){qf(this,a,b);this.s()};function O(a,b){of.call(this);this.c=[];this.j=this.v=-1;this.pa(a,b)}u(O,of);k=O.prototype;k.jk=function(a){this.B?ha(this.B,a.ia().slice()):this.B=a.ia().slice();this.c.push(this.B.length);this.s()};k.clone=function(){var a=new O(null);a.ca(this.la,this.B.slice(),this.c.slice());return a};k.Hb=function(a,b,c,d){if(d<Pa(this.D(),a,b))return d;this.j!=this.g&&(this.v=Math.sqrt(wf(this.B,0,this.c,this.a,0)),this.j=this.g);return yf(this.B,0,this.c,this.a,this.v,!1,a,b,c,d)};
k.kn=function(a,b,c){return"XYM"!=this.la&&"XYZM"!=this.la||!this.B.length?null:Ml(this.B,this.c,this.a,a,void 0!==b?b:!1,void 0!==c?c:!1)};k.W=function(){return Df(this.B,0,this.c,this.a)};k.Sb=function(){return this.c};k.Tk=function(a){if(0>a||this.c.length<=a)return null;var b=new N(null);b.ca(this.la,this.B.slice(a?this.c[a-1]:0,this.c[a]));return b};
k.Nc=function(){var a=this.B,b=this.c,c=this.la,d=[],e=0,f,g;f=0;for(g=b.length;f<g;++f){var h=b[f],l=new N(null);l.ca(c,a.slice(e,h));d.push(l);e=h}return d};function bi(a){var b=[],c=a.B,d=0,e=a.c;a=a.a;var f,g;f=0;for(g=e.length;f<g;++f){var h=e[f],d=Kl(c,d,h,a,.5);ha(b,d);d=h}return b}k.od=function(a){var b=[],c=[],d=this.B,e=this.c,f=this.a,g=0,h=0,l,m;l=0;for(m=e.length;l<m;++l){var n=e[l],h=Ef(d,g,n,f,a,b,h);c.push(h);g=n}b.length=h;a=new O(null);a.ca("XY",b,c);return a};k.S=function(){return"MultiLineString"};
k.Ya=function(a){a:{var b=this.B,c=this.c,d=this.a,e=0,f,g;f=0;for(g=c.length;f<g;++f){if(Nf(b,e,c[f],d,a)){a=!0;break a}e=c[f]}a=!1}return a};k.pa=function(a,b){if(a){rf(this,b,a,2);this.B||(this.B=[]);var c=Bf(this.B,0,a,this.a,this.c);this.B.length=c.length?c[c.length-1]:0;this.s()}else this.ca("XY",null,this.c)};k.ca=function(a,b,c){qf(this,a,b);this.c=c;this.s()};
function Nl(a,b){var c=a.la,d=[],e=[],f,g;f=0;for(g=b.length;f<g;++f){var h=b[f];f||(c=h.la);ha(d,h.ia());e.push(d.length)}a.ca(c,d,e)};function P(a,b){of.call(this);this.pa(a,b)}u(P,of);k=P.prototype;k.lk=function(a){this.B?ha(this.B,a.ia()):this.B=a.ia().slice();this.s()};k.clone=function(){var a=new P(null);a.ca(this.la,this.B.slice());return a};k.Hb=function(a,b,c,d){if(d<Pa(this.D(),a,b))return d;var e=this.B,f=this.a,g,h,l;g=0;for(h=e.length;g<h;g+=f)if(l=Ba(a,b,e[g],e[g+1]),l<d){d=l;for(l=0;l<f;++l)c[l]=e[g+l];c.length=f}return d};k.W=function(){return Cf(this.B,0,this.B.length,this.a)};
k.dl=function(a){var b=this.B?this.B.length/this.a:0;if(0>a||b<=a)return null;b=new E(null);b.ca(this.la,this.B.slice(a*this.a,(a+1)*this.a));return b};k.Zd=function(){var a=this.B,b=this.la,c=this.a,d=[],e,f;e=0;for(f=a.length;e<f;e+=c){var g=new E(null);g.ca(b,a.slice(e,e+c));d.push(g)}return d};k.S=function(){return"MultiPoint"};k.Ya=function(a){var b=this.B,c=this.a,d,e,f,g;d=0;for(e=b.length;d<e;d+=c)if(f=b[d],g=b[d+1],Sa(a,f,g))return!0;return!1};
k.pa=function(a,b){a?(rf(this,b,a,1),this.B||(this.B=[]),this.B.length=Af(this.B,0,a,this.a),this.s()):this.ca("XY",null)};k.ca=function(a,b){qf(this,a,b);this.s()};function Q(a,b){of.call(this);this.c=[];this.v=-1;this.A=null;this.I=this.C=this.G=-1;this.j=null;this.pa(a,b)}u(Q,of);k=Q.prototype;k.mk=function(a){if(this.B){var b=this.B.length;ha(this.B,a.ia());a=a.Sb().slice();var c,d;c=0;for(d=a.length;c<d;++c)a[c]+=b}else this.B=a.ia().slice(),a=a.Sb().slice(),this.c.push();this.c.push(a);this.s()};k.clone=function(){for(var a=new Q(null),b=this.c.length,c=Array(b),d=0;d<b;++d)c[d]=this.c[d].slice();Ol(a,this.la,this.B.slice(),c);return a};
k.Hb=function(a,b,c,d){if(d<Pa(this.D(),a,b))return d;if(this.C!=this.g){var e=this.c,f=0,g=0,h,l;h=0;for(l=e.length;h<l;++h)var m=e[h],g=wf(this.B,f,m,this.a,g),f=m[m.length-1];this.G=Math.sqrt(g);this.C=this.g}e=ci(this);f=this.c;g=this.a;h=this.G;l=0;var m=[NaN,NaN],n,p;n=0;for(p=f.length;n<p;++n){var q=f[n];d=yf(e,l,q,g,h,!0,a,b,c,d,m);l=q[q.length-1]}return d};
k.Sc=function(a,b){var c;a:{c=ci(this);var d=this.c,e=0;if(d.length){var f,g;f=0;for(g=d.length;f<g;++f){var h=d[f];if(Kf(c,e,h,this.a,a,b)){c=!0;break a}e=h[h.length-1]}}c=!1}return c};k.ln=function(){var a=ci(this),b=this.c,c=0,d=0,e,f;e=0;for(f=b.length;e<f;++e)var g=b[e],d=d+tf(a,c,g,this.a),c=g[g.length-1];return d};
k.W=function(a){var b;void 0!==a?(b=ci(this).slice(),Sf(b,this.c,this.a,a)):b=this.B;a=b;b=this.c;var c=this.a,d=0,e=[],f=0,g,h;g=0;for(h=b.length;g<h;++g){var l=b[g];e[f++]=Df(a,d,l,c,e[f]);d=l[l.length-1]}e.length=f;return e};
function di(a){if(a.v!=a.g){var b=a.B,c=a.c,d=a.a,e=0,f=[],g,h;g=0;for(h=c.length;g<h;++g){var l=c[g],e=Ya(b,e,l[0],d);f.push((e[0]+e[2])/2,(e[1]+e[3])/2);e=l[l.length-1]}b=ci(a);c=a.c;d=a.a;g=0;h=[];l=0;for(e=c.length;l<e;++l){var m=c[l];h=Lf(b,g,m,d,f,2*l,h);g=m[m.length-1]}a.A=h;a.v=a.g}return a.A}k.Pk=function(){var a=new P(null);a.ca("XY",di(this).slice());return a};
function ci(a){if(a.I!=a.g){var b=a.B,c;a:{c=a.c;var d,e;d=0;for(e=c.length;d<e;++d)if(!Qf(b,c[d],a.a,void 0)){c=!1;break a}c=!0}c?a.j=b:(a.j=b.slice(),a.j.length=Sf(a.j,a.c,a.a));a.I=a.g}return a.j}k.od=function(a){var b=[],c=[],d=this.B,e=this.c,f=this.a;a=Math.sqrt(a);var g=0,h=0,l,m;l=0;for(m=e.length;l<m;++l){var n=e[l],p=[],h=Ff(d,g,n,f,a,b,h,p);c.push(p);g=n[n.length-1]}b.length=h;d=new Q(null);Ol(d,"XY",b,c);return d};
k.el=function(a){if(0>a||this.c.length<=a)return null;var b;a?(b=this.c[a-1],b=b[b.length-1]):b=0;a=this.c[a].slice();var c=a[a.length-1];if(b){var d,e;d=0;for(e=a.length;d<e;++d)a[d]-=b}d=new F(null);d.ca(this.la,this.B.slice(b,c),a);return d};k.md=function(){var a=this.la,b=this.B,c=this.c,d=[],e=0,f,g,h,l;f=0;for(g=c.length;f<g;++f){var m=c[f].slice(),n=m[m.length-1];if(e)for(h=0,l=m.length;h<l;++h)m[h]-=e;h=new F(null);h.ca(a,b.slice(e,n),m);d.push(h);e=n}return d};k.S=function(){return"MultiPolygon"};
k.Ya=function(a){a:{var b=ci(this),c=this.c,d=this.a,e=0,f,g;f=0;for(g=c.length;f<g;++f){var h=c[f];if(Of(b,e,h,d,a)){a=!0;break a}e=h[h.length-1]}a=!1}return a};k.pa=function(a,b){if(a){rf(this,b,a,3);this.B||(this.B=[]);var c=this.B,d=this.a,e=this.c,f=0,e=e?e:[],g=0,h,l;h=0;for(l=a.length;h<l;++h)f=Bf(c,f,a[h],d,e[g]),e[g++]=f,f=f[f.length-1];e.length=g;e.length?(c=e[e.length-1],this.B.length=c.length?c[c.length-1]:0):this.B.length=0;this.s()}else Ol(this,"XY",null,this.c)};
function Ol(a,b,c,d){qf(a,b,c);a.c=d;a.s()}function Pl(a,b){var c=a.la,d=[],e=[],f,g,h;f=0;for(g=b.length;f<g;++f){var l=b[f];f||(c=l.la);var m=d.length;h=l.Sb();var n,p;n=0;for(p=h.length;n<p;++n)h[n]+=m;ha(d,l.ia());e.push(h)}Ol(a,c,d,e)};function Ql(a){a=a?a:{};El.call(this);this.b=a.geometryName}u(Ql,Il);
function Rl(a,b){if(!a)return null;var c;if("number"===typeof a.x&&"number"===typeof a.y)c="Point";else if(a.points)c="MultiPoint";else if(a.paths)c=1===a.paths.length?"LineString":"MultiLineString";else if(a.rings){var d=a.rings,e=Sl(a),f=[],g=[];c=[];var h,l;h=0;for(l=d.length;h<l;++h)f.length=0,Af(f,0,d[h],e.length),Pf(f,0,f.length,e.length)?g.push([d[h]]):c.push(d[h]);for(;c.length;){d=c.shift();e=!1;for(h=g.length-1;0<=h;h--)if(Ua((new Gf(g[h][0])).D(),(new Gf(d)).D())){g[h].push(d);e=!0;break}e||
g.push([d.reverse()])}a=qb({},a);1===g.length?(c="Polygon",a.rings=g[0]):(c="MultiPolygon",a.rings=g)}return Hl((0,Tl[c])(a),!1,b)}function Sl(a){var b="XY";!0===a.hasZ&&!0===a.hasM?b="XYZM":!0===a.hasZ?b="XYZ":!0===a.hasM&&(b="XYM");return b}function Ul(a){a=a.la;return{hasZ:"XYZ"===a||"XYZM"===a,hasM:"XYM"===a||"XYZM"===a}}
var Tl={Point:function(a){return void 0!==a.m&&void 0!==a.z?new E([a.x,a.y,a.z,a.m],"XYZM"):void 0!==a.z?new E([a.x,a.y,a.z],"XYZ"):void 0!==a.m?new E([a.x,a.y,a.m],"XYM"):new E([a.x,a.y])},LineString:function(a){return new N(a.paths[0],Sl(a))},Polygon:function(a){return new F(a.rings,Sl(a))},MultiPoint:function(a){return new P(a.points,Sl(a))},MultiLineString:function(a){return new O(a.paths,Sl(a))},MultiPolygon:function(a){return new Q(a.rings,Sl(a))}},Vl={Point:function(a){var b=a.W(),c;a=a.la;
"XYZ"===a?c={x:b[0],y:b[1],z:b[2]}:"XYM"===a?c={x:b[0],y:b[1],m:b[2]}:"XYZM"===a?c={x:b[0],y:b[1],z:b[2],m:b[3]}:"XY"===a?c={x:b[0],y:b[1]}:sa(!1,34);return c},LineString:function(a){var b=Ul(a);return{hasZ:b.hasZ,hasM:b.hasM,paths:[a.W()]}},Polygon:function(a){var b=Ul(a);return{hasZ:b.hasZ,hasM:b.hasM,rings:a.W(!1)}},MultiPoint:function(a){var b=Ul(a);return{hasZ:b.hasZ,hasM:b.hasM,points:a.W()}},MultiLineString:function(a){var b=Ul(a);return{hasZ:b.hasZ,hasM:b.hasM,paths:a.W()}},MultiPolygon:function(a){var b=
Ul(a);a=a.W(!1);for(var c=[],d=0;d<a.length;d++)for(var e=a[d].length-1;0<=e;e--)c.push(a[d][e]);return{hasZ:b.hasZ,hasM:b.hasM,rings:c}}};k=Ql.prototype;k.Wc=function(a,b){var c=Rl(a.geometry,b),d=new I;this.b&&d.Yc(this.b);d.Ta(c);b&&b.Zf&&a.attributes[b.Zf]&&d.lc(a.attributes[b.Zf]);a.attributes&&d.H(a.attributes);return d};
k.sg=function(a,b){var c=b?b:{};if(a.features){var d=[],e=a.features,f,g;c.Zf=a.objectIdFieldName;f=0;for(g=e.length;f<g;++f)d.push(this.Wc(e[f],c));return d}return[this.Wc(a,c)]};k.wg=function(a,b){return Rl(a,b)};k.zg=function(a){return a.spatialReference&&a.spatialReference.wkid?Tb("EPSG:"+a.spatialReference.wkid):null};function Wl(a,b){return(0,Vl[a.S()])(Hl(a,!0,b),b)}k.ie=function(a,b){return Wl(a,Gl(this,b))};
k.dd=function(a,b){b=Gl(this,b);var c={},d=a.U();d&&(c.geometry=Wl(d,b));d=a.M();delete d[a.c];c.attributes=tb(d)?{}:d;b&&b.featureProjection&&(c.spatialReference={wkid:Tb(b.featureProjection).nb.split(":").pop()});return c};k.ge=function(a,b){b=Gl(this,b);var c=[],d,e;d=0;for(e=a.length;d<e;++d)c.push(this.dd(a[d],b));return{features:c}};function Xl(a){this.mc=a};function Yl(a,b){this.mc=a;this.b=Array.prototype.slice.call(arguments,1);sa(2<=this.b.length,57)}u(Yl,Xl);function Zl(a){var b=["And"].concat(Array.prototype.slice.call(arguments));Yl.apply(this,b)}u(Zl,Yl);function $l(a,b,c){this.mc="BBOX";this.geometryName=a;this.extent=b;this.srsName=c}u($l,Xl);function am(a,b){this.mc=a;this.b=b}u(am,Xl);function bm(a,b,c,d){am.call(this,a,b);this.g=c;this.a=d}u(bm,am);function cm(a,b,c){bm.call(this,"PropertyIsEqualTo",a,b,c)}u(cm,bm);function dm(a,b){bm.call(this,"PropertyIsGreaterThan",a,b)}u(dm,bm);function em(a,b){bm.call(this,"PropertyIsGreaterThanOrEqualTo",a,b)}u(em,bm);function fm(a,b,c,d){this.mc=a;this.geometryName=b||"the_geom";this.geometry=c;this.srsName=d}u(fm,Xl);function gm(a,b,c){fm.call(this,"Intersects",a,b,c)}u(gm,fm);function hm(a,b,c){am.call(this,"PropertyIsBetween",a);this.a=b;this.g=c}u(hm,am);function im(a,b,c,d,e,f){am.call(this,"PropertyIsLike",a);this.c=b;this.f=void 0!==c?c:"*";this.i=void 0!==d?d:".";this.g=void 0!==e?e:"!";this.a=f}u(im,am);function jm(a){am.call(this,"PropertyIsNull",a)}u(jm,am);function km(a,b){bm.call(this,"PropertyIsLessThan",a,b)}u(km,bm);function lm(a,b){bm.call(this,"PropertyIsLessThanOrEqualTo",a,b)}u(lm,bm);function mm(a){this.mc="Not";this.condition=a}u(mm,Xl);function nm(a,b,c){bm.call(this,"PropertyIsNotEqualTo",a,b,c)}u(nm,bm);function om(a){var b=["Or"].concat(Array.prototype.slice.call(arguments));Yl.apply(this,b)}u(om,Yl);function pm(a,b,c){fm.call(this,"Within",a,b,c)}u(pm,fm);function qm(a){var b=[null].concat(Array.prototype.slice.call(arguments));return new (Function.prototype.bind.apply(Zl,b))}function rm(a,b,c){return new $l(a,b,c)};function sm(a){lf.call(this);this.a=a?a:null;tm(this)}u(sm,lf);function um(a){var b=[],c,d;c=0;for(d=a.length;c<d;++c)b.push(a[c].clone());return b}function vm(a){var b,c;if(a.a)for(b=0,c=a.a.length;b<c;++b)Hc(a.a[b],"change",a.s,a)}function tm(a){var b,c;if(a.a)for(b=0,c=a.a.length;b<c;++b)z(a.a[b],"change",a.s,a)}k=sm.prototype;k.clone=function(){var a=new sm(null);a.jj(this.a);return a};
k.Hb=function(a,b,c,d){if(d<Pa(this.D(),a,b))return d;var e=this.a,f,g;f=0;for(g=e.length;f<g;++f)d=e[f].Hb(a,b,c,d);return d};k.Sc=function(a,b){var c=this.a,d,e;d=0;for(e=c.length;d<e;++d)if(c[d].Sc(a,b))return!0;return!1};k.se=function(a){Wa(Infinity,Infinity,-Infinity,-Infinity,a);for(var b=this.a,c=0,d=b.length;c<d;++c)ab(a,b[c].D());return a};k.Qf=function(){return um(this.a)};
k.Td=function(a){this.l!=this.g&&(rb(this.i),this.f=0,this.l=this.g);if(0>a||this.f&&a<this.f)return this;var b=a.toString();if(this.i.hasOwnProperty(b))return this.i[b];var c=[],d=this.a,e=!1,f,g;f=0;for(g=d.length;f<g;++f){var h=d[f],l=h.Td(a);c.push(l);l!==h&&(e=!0)}if(e)return a=new sm(null),vm(a),a.a=c,tm(a),a.s(),this.i[b]=a;this.f=a;return this};k.S=function(){return"GeometryCollection"};k.Ya=function(a){var b=this.a,c,d;c=0;for(d=b.length;c<d;++c)if(b[c].Ya(a))return!0;return!1};
k.rotate=function(a,b){for(var c=this.a,d=0,e=c.length;d<e;++d)c[d].rotate(a,b);this.s()};k.scale=function(a,b,c){c||(c=kb(this.D()));for(var d=this.a,e=0,f=d.length;e<f;++e)d[e].scale(a,b,c);this.s()};k.jj=function(a){a=um(a);vm(this);this.a=a;tm(this);this.s()};k.Fc=function(a){var b=this.a,c,d;c=0;for(d=b.length;c<d;++c)b[c].Fc(a);this.s()};k.translate=function(a,b){var c=this.a,d,e;d=0;for(e=c.length;d<e;++d)c[d].translate(a,b);this.s()};k.ra=function(){vm(this);lf.prototype.ra.call(this)};function wm(a){a=a?a:{};El.call(this);this.defaultDataProjection=Tb(a.defaultDataProjection?a.defaultDataProjection:"EPSG:4326");a.featureProjection&&(this.i=Tb(a.featureProjection));this.b=a.geometryName}u(wm,Il);function xm(a,b){return a?Hl((0,ym[a.type])(a),!1,b):null}function zm(a,b){return(0,Am[a.S()])(Hl(a,!0,b),b)}
var ym={Point:function(a){return new E(a.coordinates)},LineString:function(a){return new N(a.coordinates)},Polygon:function(a){return new F(a.coordinates)},MultiPoint:function(a){return new P(a.coordinates)},MultiLineString:function(a){return new O(a.coordinates)},MultiPolygon:function(a){return new Q(a.coordinates)},GeometryCollection:function(a,b){var c=a.geometries.map(function(a){return xm(a,b)});return new sm(c)}},Am={Point:function(a){return{type:"Point",coordinates:a.W()}},LineString:function(a){return{type:"LineString",
coordinates:a.W()}},Polygon:function(a,b){var c;b&&(c=b.rightHanded);return{type:"Polygon",coordinates:a.W(c)}},MultiPoint:function(a){return{type:"MultiPoint",coordinates:a.W()}},MultiLineString:function(a){return{type:"MultiLineString",coordinates:a.W()}},MultiPolygon:function(a,b){var c;b&&(c=b.rightHanded);return{type:"MultiPolygon",coordinates:a.W(c)}},GeometryCollection:function(a,b){return{type:"GeometryCollection",geometries:a.a.map(function(a){var c=qb({},b);delete c.featureProjection;return zm(a,
c)})}},Circle:function(){return{type:"GeometryCollection",geometries:[]}}};k=wm.prototype;k.Wc=function(a,b){var c;c="Feature"===a.type?a:{type:"Feature",geometry:a};var d=xm(c.geometry,b),e=new I;this.b&&e.Yc(this.b);e.Ta(d);void 0!==c.id&&e.lc(c.id);c.properties&&e.H(c.properties);return e};k.sg=function(a,b){var c;if("FeatureCollection"===a.type){c=[];var d=a.features,e,f;e=0;for(f=d.length;e<f;++e)c.push(this.Wc(d[e],b))}else c=[this.Wc(a,b)];return c};k.wg=function(a,b){return xm(a,b)};
k.zg=function(a){a=a.crs;var b;a?"name"==a.type?b=Tb(a.properties.name):"EPSG"==a.type?b=Tb("EPSG:"+a.properties.code):sa(!1,36):b=this.defaultDataProjection;return b};k.dd=function(a,b){b=Gl(this,b);var c={type:"Feature"},d=a.a;void 0!==d&&(c.id=d);(d=a.U())?c.geometry=zm(d,b):c.geometry=null;d=a.M();delete d[a.c];tb(d)?c.properties=null:c.properties=d;return c};k.ge=function(a,b){b=Gl(this,b);var c=[],d,e;d=0;for(e=a.length;d<e;++d)c.push(this.dd(a[d],b));return{type:"FeatureCollection",features:c}};
k.ie=function(a,b){return zm(a,Gl(this,b))};function Bm(){this.g=new XMLSerializer;El.call(this)}u(Bm,El);k=Bm.prototype;k.S=function(){return"xml"};k.Vb=function(a,b){if(nl(a))return Cm(this,a,b);if(pl(a))return this.rg(a,b);if("string"===typeof a){var c=ql(a);return Cm(this,c,b)}return null};function Cm(a,b,c){a=Dm(a,b,c);return 0<a.length?a[0]:null}k.rg=function(){return null};k.Pa=function(a,b){if(nl(a))return Dm(this,a,b);if(pl(a))return this.Bc(a,b);if("string"===typeof a){var c=ql(a);return Dm(this,c,b)}return[]};
function Dm(a,b,c){var d=[];for(b=b.firstChild;b;b=b.nextSibling)b.nodeType==Node.ELEMENT_NODE&&ha(d,a.Bc(b,c));return d}k.Xc=function(a,b){if(nl(a))return null;if(pl(a))return this.Vi(a,b);"string"===typeof a&&ql(a);return null};k.Vi=function(){return null};k.jb=function(a){return nl(a)?this.yg(a):pl(a)?this.hf(a):"string"===typeof a?(a=ql(a),this.yg(a)):null};k.yg=function(){return this.defaultDataProjection};k.hf=function(){return this.defaultDataProjection};
k.Dd=function(a,b){return this.g.serializeToString(this.Ng(a,b))};k.Ng=function(){return null};k.Yb=function(a,b){var c=this.Zb(a,b);return this.g.serializeToString(c)};k.Zb=function(){return null};k.ed=function(a,b){var c=this.he(a,b);return this.g.serializeToString(c)};k.he=function(){return null};function Em(a){a=a?a:{};this.featureType=a.featureType;this.featureNS=a.featureNS;this.srsName=a.srsName;this.schemaLocation="";this.b={};this.b["http://www.opengis.net/gml"]={featureMember:tl(Em.prototype.ae),featureMembers:tl(Em.prototype.ae)};Bm.call(this)}u(Em,Bm);var Fm=/^[\s\xa0]*$/;k=Em.prototype;
k.ae=function(a,b){var c=a.localName,d=null;if("FeatureCollection"==c)"http://www.opengis.net/wfs"===a.namespaceURI?d=M([],this.b,a,b,this):d=M(null,this.b,a,b,this);else if("featureMembers"==c||"featureMember"==c){var e=b[0],f=e.featureType,g=e.featureNS,h,l;if(!f&&a.childNodes){f=[];g={};h=0;for(l=a.childNodes.length;h<l;++h){var m=a.childNodes[h];if(1===m.nodeType){var n=m.nodeName.split(":").pop();if(-1===f.indexOf(n)){var p="",q=0,m=m.namespaceURI,r;for(r in g){if(g[r]===m){p=r;break}++q}p||
(p="p"+q,g[p]=m);f.push(p+":"+n)}}}"featureMember"!=c&&(e.featureType=f,e.featureNS=g)}"string"===typeof g&&(h=g,g={},g.p0=h);var e={},f=Array.isArray(f)?f:[f],v;for(v in g){n={};h=0;for(l=f.length;h<l;++h)(-1===f[h].indexOf(":")?"p0":f[h].split(":")[0])===v&&(n[f[h].split(":").pop()]="featureMembers"==c?sl(this.qg,this):tl(this.qg,this));e[g[v]]=n}"featureMember"==c?d=M(void 0,e,a,b):d=M([],e,a,b)}null===d&&(d=[]);return d};
k.ef=function(a,b){var c=b[0];c.srsName=a.firstElementChild.getAttribute("srsName");var d=M(null,this.Rg,a,b,this);if(d)return Hl(d,!1,c)};
k.qg=function(a,b){var c,d;(d=a.getAttribute("fid"))||(d=a.getAttributeNS("http://www.opengis.net/gml","id")||"");var e={},f;for(c=a.firstElementChild;c;c=c.nextElementSibling){var g=c.localName;if(0===c.childNodes.length||1===c.childNodes.length&&(3===c.firstChild.nodeType||4===c.firstChild.nodeType)){var h=ll(c,!1);Fm.test(h)&&(h=void 0);e[g]=h}else"boundedBy"!==g&&(f=g),e[g]=this.ef(c,b)}c=new I(e);f&&c.Yc(f);d&&c.lc(d);return c};
k.$i=function(a,b){var c=this.df(a,b);if(c){var d=new E(null);d.ca("XYZ",c);return d}};k.Yi=function(a,b){var c=M([],this.Jj,a,b,this);if(c)return new P(c)};k.Xi=function(a,b){var c=M([],this.Ij,a,b,this);if(c){var d=new O(null);Nl(d,c);return d}};k.Zi=function(a,b){var c=M([],this.Kj,a,b,this);if(c){var d=new Q(null);Pl(d,c);return d}};k.Ri=function(a,b){Al(this.Nj,a,b,this)};k.Fh=function(a,b){Al(this.Gj,a,b,this)};k.Si=function(a,b){Al(this.Oj,a,b,this)};
k.ff=function(a,b){var c=this.df(a,b);if(c){var d=new N(null);d.ca("XYZ",c);return d}};k.mp=function(a,b){var c=M(null,this.je,a,b,this);if(c)return c};k.Wi=function(a,b){var c=this.df(a,b);if(c){var d=new Gf(null);Hf(d,"XYZ",c);return d}};k.gf=function(a,b){var c=M([null],this.xf,a,b,this);if(c&&c[0]){var d=new F(null),e=c[0],f=[e.length],g,h;g=1;for(h=c.length;g<h;++g)ha(e,c[g]),f.push(e.length);d.ca("XYZ",e,f);return d}};k.df=function(a,b){return M(null,this.je,a,b,this)};
k.Jj={"http://www.opengis.net/gml":{pointMember:sl(Em.prototype.Ri),pointMembers:sl(Em.prototype.Ri)}};k.Ij={"http://www.opengis.net/gml":{lineStringMember:sl(Em.prototype.Fh),lineStringMembers:sl(Em.prototype.Fh)}};k.Kj={"http://www.opengis.net/gml":{polygonMember:sl(Em.prototype.Si),polygonMembers:sl(Em.prototype.Si)}};k.Nj={"http://www.opengis.net/gml":{Point:sl(Em.prototype.df)}};k.Gj={"http://www.opengis.net/gml":{LineString:sl(Em.prototype.ff)}};k.Oj={"http://www.opengis.net/gml":{Polygon:sl(Em.prototype.gf)}};
k.ke={"http://www.opengis.net/gml":{LinearRing:tl(Em.prototype.mp)}};k.Vi=function(a,b){var c=this.ef(a,[Fl(this,a,b?b:{})]);return c?c:null};k.Bc=function(a,b){var c={featureType:this.featureType,featureNS:this.featureNS};b&&qb(c,Fl(this,a,b));return this.ae(a,[c])||[]};k.hf=function(a){return Tb(this.srsName?this.srsName:a.firstElementChild.getAttribute("srsName"))};function Gm(a){a=ll(a,!1);return Hm(a)}function Hm(a){if(a=/^\s*(true|1)|(false|0)\s*$/.exec(a))return void 0!==a[1]||!1}function Im(a){a=ll(a,!1);a=Date.parse(a);return isNaN(a)?void 0:a/1E3}function Jm(a){a=ll(a,!1);return Km(a)}function Km(a){if(a=/^\s*([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?)\s*$/i.exec(a))return parseFloat(a[1])}function Lm(a){a=ll(a,!1);return Mm(a)}function Mm(a){if(a=/^\s*(\d+)\s*$/.exec(a))return parseInt(a[1],10)}function R(a){return ll(a,!1).trim()}
function Nm(a,b){Om(a,b?"1":"0")}function Pm(a,b){a.appendChild(il.createTextNode(b.toPrecision()))}function Qm(a,b){a.appendChild(il.createTextNode(b.toString()))}function Om(a,b){a.appendChild(il.createTextNode(b))};function Rm(a){a=a?a:{};Em.call(this,a);this.o=void 0!==a.surface?a.surface:!1;this.c=void 0!==a.curve?a.curve:!1;this.f=void 0!==a.multiCurve?a.multiCurve:!0;this.j=void 0!==a.multiSurface?a.multiSurface:!0;this.schemaLocation=a.schemaLocation?a.schemaLocation:"http://www.opengis.net/gml http://schemas.opengis.net/gml/3.1.1/profiles/gmlsfProfile/1.0.0/gmlsf.xsd"}u(Rm,Em);k=Rm.prototype;k.qp=function(a,b){var c=M([],this.Hj,a,b,this);if(c){var d=new O(null);Nl(d,c);return d}};
k.rp=function(a,b){var c=M([],this.Lj,a,b,this);if(c){var d=new Q(null);Pl(d,c);return d}};k.hh=function(a,b){Al(this.Dj,a,b,this)};k.wj=function(a,b){Al(this.Rj,a,b,this)};k.up=function(a,b){return M([null],this.Mj,a,b,this)};k.xp=function(a,b){return M([null],this.Qj,a,b,this)};k.vp=function(a,b){return M([null],this.xf,a,b,this)};k.pp=function(a,b){return M([null],this.je,a,b,this)};k.Yl=function(a,b){var c=M(void 0,this.ke,a,b,this);c&&b[b.length-1].push(c)};
k.uk=function(a,b){var c=M(void 0,this.ke,a,b,this);c&&(b[b.length-1][0]=c)};k.aj=function(a,b){var c=M([null],this.Sj,a,b,this);if(c&&c[0]){var d=new F(null),e=c[0],f=[e.length],g,h;g=1;for(h=c.length;g<h;++g)ha(e,c[g]),f.push(e.length);d.ca("XYZ",e,f);return d}};k.Ti=function(a,b){var c=M([null],this.Ej,a,b,this);if(c){var d=new N(null);d.ca("XYZ",c);return d}};k.lp=function(a,b){var c=M([null],this.Fj,a,b,this);return Wa(c[1][0],c[1][1],c[2][0],c[2][1])};
k.np=function(a,b){for(var c=ll(a,!1),d=/^\s*([+\-]?\d*\.?\d+(?:[eE][+\-]?\d+)?)\s*/,e=[],f;f=d.exec(c);)e.push(parseFloat(f[1])),c=c.substr(f[0].length);if(""===c){c=b[0].srsName;d="enu";c&&(d=Tb(c).b);if("neu"===d)for(c=0,d=e.length;c<d;c+=3)f=e[c],e[c]=e[c+1],e[c+1]=f;c=e.length;2==c&&e.push(0);if(c)return e}};
k.vg=function(a,b){var c=ll(a,!1).replace(/^\s*|\s*$/g,""),d=b[0].srsName,e=a.parentNode.getAttribute("srsDimension"),f="enu";d&&(f=Tb(d).b);c=c.split(/\s+/);d=2;a.getAttribute("srsDimension")?d=Mm(a.getAttribute("srsDimension")):a.getAttribute("dimension")?d=Mm(a.getAttribute("dimension")):e&&(d=Mm(e));for(var g,h,l=[],m=0,n=c.length;m<n;m+=d)e=parseFloat(c[m]),g=parseFloat(c[m+1]),h=3===d?parseFloat(c[m+2]):0,"en"===f.substr(0,2)?l.push(e,g,h):l.push(g,e,h);return l};
k.je={"http://www.opengis.net/gml":{pos:tl(Rm.prototype.np),posList:tl(Rm.prototype.vg)}};k.xf={"http://www.opengis.net/gml":{interior:Rm.prototype.Yl,exterior:Rm.prototype.uk}};
k.Rg={"http://www.opengis.net/gml":{Point:tl(Em.prototype.$i),MultiPoint:tl(Em.prototype.Yi),LineString:tl(Em.prototype.ff),MultiLineString:tl(Em.prototype.Xi),LinearRing:tl(Em.prototype.Wi),Polygon:tl(Em.prototype.gf),MultiPolygon:tl(Em.prototype.Zi),Surface:tl(Rm.prototype.aj),MultiSurface:tl(Rm.prototype.rp),Curve:tl(Rm.prototype.Ti),MultiCurve:tl(Rm.prototype.qp),Envelope:tl(Rm.prototype.lp)}};k.Hj={"http://www.opengis.net/gml":{curveMember:sl(Rm.prototype.hh),curveMembers:sl(Rm.prototype.hh)}};
k.Lj={"http://www.opengis.net/gml":{surfaceMember:sl(Rm.prototype.wj),surfaceMembers:sl(Rm.prototype.wj)}};k.Dj={"http://www.opengis.net/gml":{LineString:sl(Em.prototype.ff),Curve:sl(Rm.prototype.Ti)}};k.Rj={"http://www.opengis.net/gml":{Polygon:sl(Em.prototype.gf),Surface:sl(Rm.prototype.aj)}};k.Sj={"http://www.opengis.net/gml":{patches:tl(Rm.prototype.up)}};k.Ej={"http://www.opengis.net/gml":{segments:tl(Rm.prototype.xp)}};k.Fj={"http://www.opengis.net/gml":{lowerCorner:sl(Rm.prototype.vg),upperCorner:sl(Rm.prototype.vg)}};
k.Mj={"http://www.opengis.net/gml":{PolygonPatch:tl(Rm.prototype.vp)}};k.Qj={"http://www.opengis.net/gml":{LineStringSegment:tl(Rm.prototype.pp)}};function Sm(a,b,c){c=c[c.length-1].srsName;b=b.W();for(var d=b.length,e=Array(d),f,g=0;g<d;++g){f=b[g];var h=g,l="enu";c&&(l=Tb(c).b);e[h]="en"===l.substr(0,2)?f[0]+" "+f[1]:f[1]+" "+f[0]}Om(a,e.join(" "))}
k.gi=function(a,b,c){var d=c[c.length-1].srsName;d&&a.setAttribute("srsName",d);d=kl(a.namespaceURI,"pos");a.appendChild(d);c=c[c.length-1].srsName;a="enu";c&&(a=Tb(c).b);b=b.W();Om(d,"en"===a.substr(0,2)?b[0]+" "+b[1]:b[1]+" "+b[0])};var Tm={"http://www.opengis.net/gml":{lowerCorner:K(Om),upperCorner:K(Om)}};k=Rm.prototype;k.cn=function(a,b,c){var d=c[c.length-1].srsName;d&&a.setAttribute("srsName",d);Bl({node:a},Tm,yl,[b[0]+" "+b[1],b[2]+" "+b[3]],c,["lowerCorner","upperCorner"],this)};
k.di=function(a,b,c){var d=c[c.length-1].srsName;d&&a.setAttribute("srsName",d);d=kl(a.namespaceURI,"posList");a.appendChild(d);Sm(d,b,c)};k.bn=function(a,b){var c=b[b.length-1],d=c.node,e=c.exteriorWritten;void 0===e&&(c.exteriorWritten=!0);return kl(d.namespaceURI,void 0!==e?"interior":"exterior")};
k.Re=function(a,b,c){var d=c[c.length-1].srsName;"PolygonPatch"!==a.nodeName&&d&&a.setAttribute("srsName",d);"Polygon"===a.nodeName||"PolygonPatch"===a.nodeName?(b=b.Oc(),Bl({node:a,srsName:d},Um,this.bn,b,c,void 0,this)):"Surface"===a.nodeName&&(d=kl(a.namespaceURI,"patches"),a.appendChild(d),a=kl(d.namespaceURI,"PolygonPatch"),d.appendChild(a),this.Re(a,b,c))};
k.Qe=function(a,b,c){var d=c[c.length-1].srsName;"LineStringSegment"!==a.nodeName&&d&&a.setAttribute("srsName",d);"LineString"===a.nodeName||"LineStringSegment"===a.nodeName?(d=kl(a.namespaceURI,"posList"),a.appendChild(d),Sm(d,b,c)):"Curve"===a.nodeName&&(d=kl(a.namespaceURI,"segments"),a.appendChild(d),a=kl(d.namespaceURI,"LineStringSegment"),d.appendChild(a),this.Qe(a,b,c))};
k.fi=function(a,b,c){var d=c[c.length-1],e=d.srsName,d=d.surface;e&&a.setAttribute("srsName",e);b=b.md();Bl({node:a,srsName:e,surface:d},Vm,this.l,b,c,void 0,this)};k.dn=function(a,b,c){var d=c[c.length-1].srsName;d&&a.setAttribute("srsName",d);b=b.Zd();Bl({node:a,srsName:d},Wm,wl("pointMember"),b,c,void 0,this)};k.ei=function(a,b,c){var d=c[c.length-1],e=d.srsName,d=d.curve;e&&a.setAttribute("srsName",e);b=b.Nc();Bl({node:a,srsName:e,curve:d},Xm,this.l,b,c,void 0,this)};
k.hi=function(a,b,c){var d=kl(a.namespaceURI,"LinearRing");a.appendChild(d);this.di(d,b,c)};k.ii=function(a,b,c){var d=this.a(b,c);d&&(a.appendChild(d),this.Re(d,b,c))};k.en=function(a,b,c){var d=kl(a.namespaceURI,"Point");a.appendChild(d);this.gi(d,b,c)};k.ci=function(a,b,c){var d=this.a(b,c);d&&(a.appendChild(d),this.Qe(d,b,c))};
k.rd=function(a,b,c){var d=c[c.length-1],e=qb({},d);e.node=a;var f;Array.isArray(b)?d.dataProjection?f=gc(b,d.featureProjection,d.dataProjection):f=b:f=Hl(b,!0,d);Bl(e,Ym,this.a,[f],c,void 0,this)};
k.bi=function(a,b,c){var d=b.a;d&&a.setAttribute("fid",d);var d=c[c.length-1],e=d.featureNS,f=b.c;d.kb||(d.kb={},d.kb[e]={});var g=b.M();b=[];var h=[],l;for(l in g){var m=g[l];null!==m&&(b.push(l),h.push(m),l==f||m instanceof lf?l in d.kb[e]||(d.kb[e][l]=K(this.rd,this)):l in d.kb[e]||(d.kb[e][l]=K(Om)))}l=qb({},d);l.node=a;Bl(l,d.kb,wl(void 0,e),h,c,b)};
var Vm={"http://www.opengis.net/gml":{surfaceMember:K(Rm.prototype.ii),polygonMember:K(Rm.prototype.ii)}},Wm={"http://www.opengis.net/gml":{pointMember:K(Rm.prototype.en)}},Xm={"http://www.opengis.net/gml":{lineStringMember:K(Rm.prototype.ci),curveMember:K(Rm.prototype.ci)}},Um={"http://www.opengis.net/gml":{exterior:K(Rm.prototype.hi),interior:K(Rm.prototype.hi)}},Ym={"http://www.opengis.net/gml":{Curve:K(Rm.prototype.Qe),MultiCurve:K(Rm.prototype.ei),Point:K(Rm.prototype.gi),MultiPoint:K(Rm.prototype.dn),
LineString:K(Rm.prototype.Qe),MultiLineString:K(Rm.prototype.ei),LinearRing:K(Rm.prototype.di),Polygon:K(Rm.prototype.Re),MultiPolygon:K(Rm.prototype.fi),Surface:K(Rm.prototype.Re),MultiSurface:K(Rm.prototype.fi),Envelope:K(Rm.prototype.cn)}},Zm={MultiLineString:"lineStringMember",MultiCurve:"curveMember",MultiPolygon:"polygonMember",MultiSurface:"surfaceMember"};Rm.prototype.l=function(a,b){return kl("http://www.opengis.net/gml",Zm[b[b.length-1].node.nodeName])};
Rm.prototype.a=function(a,b){var c=b[b.length-1],d=c.multiSurface,e=c.surface,f=c.curve,c=c.multiCurve,g;Array.isArray(a)?g="Envelope":(g=a.S(),"MultiPolygon"===g&&!0===d?g="MultiSurface":"Polygon"===g&&!0===e?g="Surface":"LineString"===g&&!0===f?g="Curve":"MultiLineString"===g&&!0===c&&(g="MultiCurve"));return kl("http://www.opengis.net/gml",g)};
Rm.prototype.he=function(a,b){b=Gl(this,b);var c=kl("http://www.opengis.net/gml","geom"),d={node:c,srsName:this.srsName,curve:this.c,surface:this.o,multiSurface:this.j,multiCurve:this.f};b&&qb(d,b);this.rd(c,a,[d]);return c};
Rm.prototype.Zb=function(a,b){b=Gl(this,b);var c=kl("http://www.opengis.net/gml","featureMembers");c.setAttributeNS("http://www.w3.org/2001/XMLSchema-instance","xsi:schemaLocation",this.schemaLocation);var d={srsName:this.srsName,curve:this.c,surface:this.o,multiSurface:this.j,multiCurve:this.f,featureNS:this.featureNS,featureType:this.featureType};b&&qb(d,b);var d=[d],e=d[d.length-1],f=e.featureType,g=e.featureNS,h={};h[g]={};h[g][f]=K(this.bi,this);e=qb({},e);e.node=c;Bl(e,h,wl(f,g),a,d);return c};function $m(a){a=a?a:{};Em.call(this,a);this.b["http://www.opengis.net/gml"].featureMember=sl(Em.prototype.ae);this.schemaLocation=a.schemaLocation?a.schemaLocation:"http://www.opengis.net/gml http://schemas.opengis.net/gml/2.1.2/feature.xsd"}u($m,Em);k=$m.prototype;
k.Ui=function(a,b){var c=ll(a,!1).replace(/^\s*|\s*$/g,""),d=b[0].srsName,e="enu";d&&(d=Tb(d))&&(e=d.b);for(var c=c.trim().split(/\s+/),f,g,h=[],l=0,m=c.length;l<m;l++)g=c[l].split(/,+/),d=parseFloat(g[0]),f=parseFloat(g[1]),g=3===g.length?parseFloat(g[2]):0,"en"===e.substr(0,2)?h.push(d,f,g):h.push(f,d,g);return h};k.jp=function(a,b){var c=M([null],this.Cj,a,b,this);return Wa(c[1][0],c[1][1],c[1][3],c[1][4])};k.Wl=function(a,b){var c=M(void 0,this.ke,a,b,this);c&&b[b.length-1].push(c)};
k.So=function(a,b){var c=M(void 0,this.ke,a,b,this);c&&(b[b.length-1][0]=c)};k.je={"http://www.opengis.net/gml":{coordinates:tl($m.prototype.Ui)}};k.xf={"http://www.opengis.net/gml":{innerBoundaryIs:$m.prototype.Wl,outerBoundaryIs:$m.prototype.So}};k.Cj={"http://www.opengis.net/gml":{coordinates:sl($m.prototype.Ui)}};
k.Rg={"http://www.opengis.net/gml":{Point:tl(Em.prototype.$i),MultiPoint:tl(Em.prototype.Yi),LineString:tl(Em.prototype.ff),MultiLineString:tl(Em.prototype.Xi),LinearRing:tl(Em.prototype.Wi),Polygon:tl(Em.prototype.gf),MultiPolygon:tl(Em.prototype.Zi),Box:tl($m.prototype.jp)}};
k.eg=function(a,b){var c=b[b.length-1],d=c.multiSurface,e=c.surface,c=c.multiCurve,f;Array.isArray(a)?f="Envelope":(f=a.S(),"MultiPolygon"===f&&!0===d?f="MultiSurface":"Polygon"===f&&!0===e?f="Surface":"MultiLineString"===f&&!0===c&&(f="MultiCurve"));return kl("http://www.opengis.net/gml",f)};k.Uh=function(a,b,c){var d=c[c.length-1],e=qb({},d);e.node=a;var f;Array.isArray(b)?d.dataProjection?f=gc(b,d.featureProjection,d.dataProjection):f=b:f=Hl(b,!0,d);Bl(e,an,this.eg,[f],c,void 0,this)};
k.Oe=function(a,b,c){var d=c[c.length-1].srsName;"LineStringSegment"!==a.nodeName&&d&&a.setAttribute("srsName",d);"LineString"===a.nodeName||"LineStringSegment"===a.nodeName?(d=bn(a.namespaceURI),a.appendChild(d),cn(d,b,c)):"Curve"===a.nodeName&&(d=kl(a.namespaceURI,"segments"),a.appendChild(d),a=kl(d.namespaceURI,"LineStringSegment"),d.appendChild(a),this.Oe(a,b,c))};function bn(a){a=kl(a,"coordinates");a.setAttribute("decimal",".");a.setAttribute("cs",",");a.setAttribute("ts"," ");return a}
function cn(a,b,c){c=c[c.length-1].srsName;b=b.W();for(var d=b.length,e=Array(d),f,g=0;g<d;++g)f=b[g],e[g]=dn(f,c);Om(a,e.join(" "))}k.Pe=function(a,b,c){var d=c[c.length-1].srsName;"PolygonPatch"!==a.nodeName&&d&&a.setAttribute("srsName",d);"Polygon"===a.nodeName||"PolygonPatch"===a.nodeName?(b=b.Oc(),Bl({node:a,srsName:d},en,this.Ym,b,c,void 0,this)):"Surface"===a.nodeName&&(d=kl(a.namespaceURI,"patches"),a.appendChild(d),a=kl(d.namespaceURI,"PolygonPatch"),d.appendChild(a),this.Pe(a,b,c))};
k.Ym=function(a,b){var c=b[b.length-1],d=c.node,e=c.exteriorWritten;void 0===e&&(c.exteriorWritten=!0);return kl(d.namespaceURI,void 0!==e?"innerBoundaryIs":"outerBoundaryIs")};k.$h=function(a,b,c){var d=kl(a.namespaceURI,"LinearRing");a.appendChild(d);this.Wh(d,b,c)};function dn(a,b){var c="enu";b&&(c=Tb(b).b);return"en"===c.substr(0,2)?a[0]+","+a[1]:a[1]+","+a[0]}
k.Xh=function(a,b,c){var d=c[c.length-1],e=d.srsName,d=d.curve;e&&a.setAttribute("srsName",e);b=b.Nc();Bl({node:a,srsName:e,curve:d},fn,this.a,b,c,void 0,this)};k.Zh=function(a,b,c){var d=c[c.length-1].srsName;d&&a.setAttribute("srsName",d);c=bn(a.namespaceURI);a.appendChild(c);a=b.W();a=dn(a,d);Om(c,a)};k.$m=function(a,b,c){var d=c[c.length-1].srsName;d&&a.setAttribute("srsName",d);b=b.Zd();Bl({node:a,srsName:d},gn,wl("pointMember"),b,c,void 0,this)};
k.an=function(a,b,c){var d=kl(a.namespaceURI,"Point");a.appendChild(d);this.Zh(d,b,c)};k.Vh=function(a,b,c){var d=this.eg(b,c);d&&(a.appendChild(d),this.Oe(d,b,c))};k.Wh=function(a,b,c){var d=c[c.length-1].srsName;d&&a.setAttribute("srsName",d);d=bn(a.namespaceURI);a.appendChild(d);cn(d,b,c)};k.Yh=function(a,b,c){var d=c[c.length-1],e=d.srsName,d=d.surface;e&&a.setAttribute("srsName",e);b=b.md();Bl({node:a,srsName:e,surface:d},hn,this.a,b,c,void 0,this)};
k.ai=function(a,b,c){var d=this.eg(b,c);d&&(a.appendChild(d),this.Pe(d,b,c))};k.Zm=function(a,b,c){var d=c[c.length-1].srsName;d&&a.setAttribute("srsName",d);Bl({node:a},jn,yl,[b[0]+" "+b[1],b[2]+" "+b[3]],c,["lowerCorner","upperCorner"],this)};
var an={"http://www.opengis.net/gml":{Curve:K($m.prototype.Oe),MultiCurve:K($m.prototype.Xh),Point:K($m.prototype.Zh),MultiPoint:K($m.prototype.$m),LineString:K($m.prototype.Oe),MultiLineString:K($m.prototype.Xh),LinearRing:K($m.prototype.Wh),Polygon:K($m.prototype.Pe),MultiPolygon:K($m.prototype.Yh),Surface:K($m.prototype.Pe),MultiSurface:K($m.prototype.Yh),Envelope:K($m.prototype.Zm)}},en={"http://www.opengis.net/gml":{outerBoundaryIs:K($m.prototype.$h),innerBoundaryIs:K($m.prototype.$h)}},gn={"http://www.opengis.net/gml":{pointMember:K($m.prototype.an)}},
fn={"http://www.opengis.net/gml":{lineStringMember:K($m.prototype.Vh),curveMember:K($m.prototype.Vh)}};$m.prototype.a=function(a,b){return kl("http://www.opengis.net/gml",kn[b[b.length-1].node.nodeName])};var kn={MultiLineString:"lineStringMember",MultiCurve:"curveMember",MultiPolygon:"polygonMember",MultiSurface:"surfaceMember"},hn={"http://www.opengis.net/gml":{surfaceMember:K($m.prototype.ai),polygonMember:K($m.prototype.ai)}},jn={"http://www.opengis.net/gml":{lowerCorner:K(Om),upperCorner:K(Om)}};function ln(a){a=a?a:{};Bm.call(this);this.defaultDataProjection=Tb("EPSG:4326");this.b=a.readExtensions}u(ln,Bm);var mn=[null,"http://www.topografix.com/GPX/1/0","http://www.topografix.com/GPX/1/1"];function nn(a,b,c,d){a.push(parseFloat(c.getAttribute("lon")),parseFloat(c.getAttribute("lat")));"ele"in d?(a.push(d.ele),delete d.ele,b.hasZ=!0):a.push(0);"time"in d?(a.push(d.time),delete d.time,b.hasM=!0):a.push(0);return a}
function on(a,b,c){var d="XY",e=2;a.hasZ&&a.hasM?(d="XYZM",e=4):a.hasZ?(d="XYZ",e=3):a.hasM&&(d="XYM",e=3);if(4!==e){var f,g;f=0;for(g=b.length/4;f<g;f++)b[f*e]=b[4*f],b[f*e+1]=b[4*f+1],a.hasZ&&(b[f*e+2]=b[4*f+2]),a.hasM&&(b[f*e+2]=b[4*f+3]);b.length=b.length/4*e;if(c)for(f=0,g=c.length;f<g;f++)c[f]=c[f]/4*e}return d}function pn(a,b){var c=b[b.length-1],d=a.getAttribute("href");null!==d&&(c.link=d);Al(qn,a,b)}function rn(a,b){b[b.length-1].extensionsNode_=a}
function sn(a,b){var c=b[0],d=M({flatCoordinates:[],layoutOptions:{}},tn,a,b);if(d){var e=d.flatCoordinates;delete d.flatCoordinates;var f=d.layoutOptions;delete d.layoutOptions;var f=on(f,e),g=new N(null);g.ca(f,e);Hl(g,!1,c);c=new I(g);c.H(d);return c}}
function un(a,b){var c=b[0],d=M({flatCoordinates:[],ends:[],layoutOptions:{}},vn,a,b);if(d){var e=d.flatCoordinates;delete d.flatCoordinates;var f=d.ends;delete d.ends;var g=d.layoutOptions;delete d.layoutOptions;var g=on(g,e,f),h=new O(null);h.ca(g,e,f);Hl(h,!1,c);c=new I(h);c.H(d);return c}}function wn(a,b){var c=b[0],d=M({},xn,a,b);if(d){var e={},f=nn([],e,a,d),e=on(e,f),f=new E(f,e);Hl(f,!1,c);c=new I(f);c.H(d);return c}}
var yn={rte:sn,trk:un,wpt:wn},zn=L(mn,{rte:sl(sn),trk:sl(un),wpt:sl(wn)}),qn=L(mn,{text:J(R,"linkText"),type:J(R,"linkType")}),tn=L(mn,{name:J(R),cmt:J(R),desc:J(R),src:J(R),link:pn,number:J(Lm),extensions:rn,type:J(R),rtept:function(a,b){var c=M({},An,a,b);if(c){var d=b[b.length-1];nn(d.flatCoordinates,d.layoutOptions,a,c)}}}),An=L(mn,{ele:J(Jm),time:J(Im)}),vn=L(mn,{name:J(R),cmt:J(R),desc:J(R),src:J(R),link:pn,number:J(Lm),type:J(R),extensions:rn,trkseg:function(a,b){var c=b[b.length-1];Al(Bn,
a,b);c.ends.push(c.flatCoordinates.length)}}),Bn=L(mn,{trkpt:function(a,b){var c=M({},Cn,a,b);if(c){var d=b[b.length-1];nn(d.flatCoordinates,d.layoutOptions,a,c)}}}),Cn=L(mn,{ele:J(Jm),time:J(Im)}),xn=L(mn,{ele:J(Jm),time:J(Im),magvar:J(Jm),geoidheight:J(Jm),name:J(R),cmt:J(R),desc:J(R),src:J(R),link:pn,sym:J(R),type:J(R),fix:J(R),sat:J(Lm),hdop:J(Jm),vdop:J(Jm),pdop:J(Jm),ageofdgpsdata:J(Jm),dgpsid:J(Lm),extensions:rn});
function Dn(a,b){b||(b=[]);for(var c=0,d=b.length;c<d;++c){var e=b[c];if(a.b){var f=e.get("extensionsNode_")||null;a.b(e,f)}e.set("extensionsNode_",void 0)}}ln.prototype.rg=function(a,b){if(!fa(mn,a.namespaceURI))return null;var c=yn[a.localName];if(!c)return null;c=c(a,[Fl(this,a,b)]);if(!c)return null;Dn(this,[c]);return c};ln.prototype.Bc=function(a,b){if(!fa(mn,a.namespaceURI))return[];if("gpx"==a.localName){var c=M([],zn,a,[Fl(this,a,b)]);if(c)return Dn(this,c),c}return[]};
function En(a,b,c){a.setAttribute("href",b);b=c[c.length-1].properties;Bl({node:a},Fn,yl,[b.linkText,b.linkType],c,Gn)}function Hn(a,b,c){var d=c[c.length-1],e=d.node.namespaceURI,f=d.properties;a.setAttributeNS(null,"lat",b[1]);a.setAttributeNS(null,"lon",b[0]);switch(d.geometryLayout){case "XYZM":b[3]&&(f.time=b[3]);case "XYZ":b[2]&&(f.ele=b[2]);break;case "XYM":b[2]&&(f.time=b[2])}b="rtept"==a.nodeName?In[e]:Jn[e];d=zl(f,b);Bl({node:a,properties:f},Kn,yl,d,c,b)}
var Gn=["text","type"],Fn=L(mn,{text:K(Om),type:K(Om)}),Ln=L(mn,"name cmt desc src link number type rtept".split(" ")),Mn=L(mn,{name:K(Om),cmt:K(Om),desc:K(Om),src:K(Om),link:K(En),number:K(Qm),type:K(Om),rtept:vl(K(Hn))}),In=L(mn,["ele","time"]),Nn=L(mn,"name cmt desc src link number type trkseg".split(" ")),Qn=L(mn,{name:K(Om),cmt:K(Om),desc:K(Om),src:K(Om),link:K(En),number:K(Qm),type:K(Om),trkseg:vl(K(function(a,b,c){Bl({node:a,geometryLayout:b.la,properties:{}},On,Pn,b.W(),c)}))}),Pn=wl("trkpt"),
On=L(mn,{trkpt:K(Hn)}),Jn=L(mn,"ele time magvar geoidheight name cmt desc src link sym type fix sat hdop vdop pdop ageofdgpsdata dgpsid".split(" ")),Kn=L(mn,{ele:K(Pm),time:K(function(a,b){var c=new Date(1E3*b);a.appendChild(il.createTextNode(c.getUTCFullYear()+"-"+Ve(c.getUTCMonth()+1)+"-"+Ve(c.getUTCDate())+"T"+Ve(c.getUTCHours())+":"+Ve(c.getUTCMinutes())+":"+Ve(c.getUTCSeconds())+"Z"))}),magvar:K(Pm),geoidheight:K(Pm),name:K(Om),cmt:K(Om),desc:K(Om),src:K(Om),link:K(En),sym:K(Om),type:K(Om),fix:K(Om),
sat:K(Qm),hdop:K(Pm),vdop:K(Pm),pdop:K(Pm),ageofdgpsdata:K(Pm),dgpsid:K(Qm)}),Rn={Point:"wpt",LineString:"rte",MultiLineString:"trk"};function Sn(a,b){var c=a.U();if(c&&(c=Rn[c.S()]))return kl(b[b.length-1].node.namespaceURI,c)}
var Tn=L(mn,{rte:K(function(a,b,c){var d=c[0],e=b.M();a={node:a,properties:e};if(b=b.U())b=Hl(b,!0,d),a.geometryLayout=b.la,e.rtept=b.W();d=Ln[c[c.length-1].node.namespaceURI];e=zl(e,d);Bl(a,Mn,yl,e,c,d)}),trk:K(function(a,b,c){var d=c[0],e=b.M();a={node:a,properties:e};if(b=b.U())b=Hl(b,!0,d),e.trkseg=b.Nc();d=Nn[c[c.length-1].node.namespaceURI];e=zl(e,d);Bl(a,Qn,yl,e,c,d)}),wpt:K(function(a,b,c){var d=c[0],e=c[c.length-1];e.properties=b.M();if(b=b.U())b=Hl(b,!0,d),e.geometryLayout=b.la,Hn(a,b.W(),
c)})});ln.prototype.Zb=function(a,b){b=Gl(this,b);var c=kl("http://www.topografix.com/GPX/1/1","gpx");c.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xsi","http://www.w3.org/2001/XMLSchema-instance");c.setAttributeNS("http://www.w3.org/2001/XMLSchema-instance","xsi:schemaLocation","http://www.topografix.com/GPX/1/1 http://www.topografix.com/GPX/1/1/gpx.xsd");c.setAttribute("version","1.1");c.setAttribute("creator","OpenLayers");Bl({node:c},Tn,Sn,a,[b]);return c};function Un(){El.call(this)}u(Un,El);function Vn(a){return"string"===typeof a?a:""}k=Un.prototype;k.S=function(){return"text"};k.Vb=function(a,b){return this.$d(Vn(a),Gl(this,b))};k.Pa=function(a,b){return this.tg(Vn(a),Gl(this,b))};k.Xc=function(a,b){return this.yd(Vn(a),Gl(this,b))};k.jb=function(){return this.defaultDataProjection};k.Dd=function(a,b){return this.fe(a,Gl(this,b))};k.Yb=function(a,b){return this.Og(a,Gl(this,b))};k.ed=function(a,b){return this.Ed(a,Gl(this,b))};function Wn(a){a=a?a:{};El.call(this);this.defaultDataProjection=Tb("EPSG:4326");this.b=a.altitudeMode?a.altitudeMode:"none"}u(Wn,Un);var Xn=/^B(\d{2})(\d{2})(\d{2})(\d{2})(\d{5})([NS])(\d{3})(\d{5})([EW])([AV])(\d{5})(\d{5})/,Yn=/^H.([A-Z]{3}).*?:(.*)/,Zn=/^HFDTE(\d{2})(\d{2})(\d{2})/,$n=/\r\n|\r|\n/;k=Wn.prototype;
k.$d=function(a,b){var c=this.b,d=a.split($n),e={},f=[],g=2E3,h=0,l=1,m=-1,n,p;n=0;for(p=d.length;n<p;++n){var q=d[n],r;if("B"==q.charAt(0)){if(r=Xn.exec(q)){var q=parseInt(r[1],10),v=parseInt(r[2],10),x=parseInt(r[3],10),y=parseInt(r[4],10)+parseInt(r[5],10)/6E4;"S"==r[6]&&(y=-y);var A=parseInt(r[7],10)+parseInt(r[8],10)/6E4;"W"==r[9]&&(A=-A);f.push(A,y);"none"!=c&&f.push("gps"==c?parseInt(r[11],10):"barometric"==c?parseInt(r[12],10):0);r=Date.UTC(g,h,l,q,v,x);r<m&&(r=Date.UTC(g,h,l+1,q,v,x));f.push(r/
1E3);m=r}}else"H"==q.charAt(0)&&((r=Zn.exec(q))?(l=parseInt(r[1],10),h=parseInt(r[2],10)-1,g=2E3+parseInt(r[3],10)):(r=Yn.exec(q))&&(e[r[1]]=r[2].trim()))}if(!f.length)return null;d=new N(null);d.ca("none"==c?"XYM":"XYZM",f);c=new I(Hl(d,!1,b));c.H(e);return c};k.tg=function(a,b){var c=this.$d(a,b);return c?[c]:[]};k.fe=function(){};k.Og=function(){};k.Ed=function(){};k.yd=function(){};function ao(a,b,c,d,e,f){Nc.call(this);this.j=null;this.N=a?a:new Image;null!==d&&(this.N.crossOrigin=d);this.c=f?document.createElement("CANVAS"):null;this.f=f;this.i=null;this.g=e;this.a=c;this.l=b;this.o=!1;2==this.g&&bo(this)}u(ao,Nc);function bo(a){var b=hd(1,1);try{b.drawImage(a.N,0,0),b.getImageData(0,0,1,1)}catch(c){a.o=!0}}ao.prototype.u=function(){this.g=3;this.i.forEach(Bc);this.i=null;this.b("change")};
ao.prototype.v=function(){this.g=2;this.a&&(this.N.width=this.a[0],this.N.height=this.a[1]);this.a=[this.N.width,this.N.height];this.i.forEach(Bc);this.i=null;bo(this);if(!this.o&&null!==this.f){this.c.width=this.N.width;this.c.height=this.N.height;var a=this.c.getContext("2d");a.drawImage(this.N,0,0);for(var b=a.getImageData(0,0,this.N.width,this.N.height),c=b.data,d=this.f[0]/255,e=this.f[1]/255,f=this.f[2]/255,g=0,h=c.length;g<h;g+=4)c[g]*=d,c[g+1]*=e,c[g+2]*=f;a.putImageData(b,0,0)}this.b("change")};
ao.prototype.Y=function(){return this.c?this.c:this.N};ao.prototype.load=function(){if(0==this.g){this.g=1;this.i=[Gc(this.N,"error",this.u,this),Gc(this.N,"load",this.v,this)];try{this.N.src=this.l}catch(a){this.u()}}};function co(a){a=a||{};this.l=void 0!==a.anchor?a.anchor:[.5,.5];this.v=null;this.a=void 0!==a.anchorOrigin?a.anchorOrigin:"top-left";this.C=void 0!==a.anchorXUnits?a.anchorXUnits:"fraction";this.G=void 0!==a.anchorYUnits?a.anchorYUnits:"fraction";this.ta=void 0!==a.crossOrigin?a.crossOrigin:null;var b=void 0!==a.img?a.img:null,c=void 0!==a.imgSize?a.imgSize:null,d=a.src;sa(!(void 0!==d&&b),4);sa(!b||b&&c,5);void 0!==d&&d.length||!b||(d=b.src||w(b).toString());sa(void 0!==d&&0<d.length,6);var e=void 0!==
a.src?0:2;this.i=void 0!==a.color?bd(a.color):null;var f=this.ta,g=this.i,h=wh.get(d,f,g);h||(h=new ao(b,d,c,f,e,g),wh.set(d,f,g,h));this.b=h;this.qa=void 0!==a.offset?a.offset:[0,0];this.g=void 0!==a.offsetOrigin?a.offsetOrigin:"top-left";this.O=null;this.A=void 0!==a.size?a.size:null;Xk.call(this,{opacity:void 0!==a.opacity?a.opacity:1,rotation:void 0!==a.rotation?a.rotation:0,scale:void 0!==a.scale?a.scale:1,snapToPixel:void 0!==a.snapToPixel?a.snapToPixel:!0,rotateWithView:void 0!==a.rotateWithView?
a.rotateWithView:!1})}u(co,Xk);k=co.prototype;
k.clone=function(){var a=this.Y(1),b;if(2===this.b.g)if("IMG"===a.tagName.toUpperCase())b=a.cloneNode(!0);else{b=document.createElement("canvas");var c=b.getContext("2d");b.width=a.width;b.height=a.height;c.drawImage(a,0,0)}return new co({anchor:this.l.slice(),anchorOrigin:this.a,anchorXUnits:this.C,anchorYUnits:this.G,crossOrigin:this.ta,color:this.i&&this.i.slice?this.i.slice():this.i||void 0,img:b?b:void 0,imgSize:b?this.b.a.slice():void 0,src:b?void 0:this.b.l,offset:this.qa.slice(),offsetOrigin:this.g,
size:null!==this.A?this.A.slice():void 0,opacity:this.f,scale:this.c,snapToPixel:this.u,rotation:this.j,rotateWithView:this.o})};
k.Jc=function(){if(this.v)return this.v;var a=this.l,b=this.kc();if("fraction"==this.C||"fraction"==this.G){if(!b)return null;a=this.l.slice();"fraction"==this.C&&(a[0]*=b[0]);"fraction"==this.G&&(a[1]*=b[1])}if("top-left"!=this.a){if(!b)return null;a===this.l&&(a=this.l.slice());if("top-right"==this.a||"bottom-right"==this.a)a[0]=-a[0]+b[0];if("bottom-left"==this.a||"bottom-right"==this.a)a[1]=-a[1]+b[1]}return this.v=a};k.Bo=function(){return this.i};k.Y=function(a){return this.b.Y(a)};k.ye=function(){return this.b.a};
k.Xe=function(){return this.b.g};k.kg=function(){var a=this.b;if(!a.j)if(a.o){var b=a.a[0],c=a.a[1],d=hd(b,c);d.fillRect(0,0,b,c);a.j=d.canvas}else a.j=a.N;return a.j};k.Tc=function(){if(this.O)return this.O;var a=this.qa;if("top-left"!=this.g){var b=this.kc(),c=this.b.a;if(!b||!c)return null;a=a.slice();if("top-right"==this.g||"bottom-right"==this.g)a[0]=c[0]-b[0]-a[0];if("bottom-left"==this.g||"bottom-right"==this.g)a[1]=c[1]-b[1]-a[1]}return this.O=a};k.Co=function(){return this.b.l};
k.kc=function(){return this.A?this.A:this.b.a};k.Gh=function(a,b){return z(this.b,"change",a,b)};k.load=function(){this.b.load()};k.xj=function(a,b){Hc(this.b,"change",a,b)};function eo(a){a=a||{};this.a=a.font;this.i=a.rotation;this.l=a.rotateWithView;this.b=a.scale;this.Fa=a.text;this.f=a.textAlign;this.j=a.textBaseline;this.Wa=void 0!==a.fill?a.fill:new al({color:"#333"});this.Za=void 0!==a.stroke?a.stroke:null;this.g=void 0!==a.offsetX?a.offsetX:0;this.c=void 0!==a.offsetY?a.offsetY:0}k=eo.prototype;
k.clone=function(){return new eo({font:this.a,rotation:this.i,rotateWithView:this.l,scale:this.b,text:this.Oa(),textAlign:this.f,textBaseline:this.j,fill:this.Ca()?this.Ca().clone():void 0,stroke:this.Da()?this.Da().clone():void 0,offsetX:this.g,offsetY:this.c})};k.Jk=function(){return this.a};k.Yk=function(){return this.g};k.Zk=function(){return this.c};k.Ca=function(){return this.Wa};k.Ho=function(){return this.l};k.Io=function(){return this.i};k.Jo=function(){return this.b};k.Da=function(){return this.Za};
k.Oa=function(){return this.Fa};k.il=function(){return this.f};k.jl=function(){return this.j};k.ij=function(a){this.a=a};k.oj=function(a){this.g=a};k.pj=function(a){this.c=a};k.mf=function(a){this.Wa=a};k.Ko=function(a){this.i=a};k.Mi=function(a){this.b=a};k.nf=function(a){this.Za=a};k.pf=function(a){this.Fa=a};k.rj=function(a){this.f=a};k.Xp=function(a){this.j=a};function fo(a){a=a?a:{};Bm.call(this);go||(ho=[255,255,255,1],io=new al({color:ho}),jo=[20,2],ko=lo="pixels",mo=[64,64],no="https://maps.google.com/mapfiles/kml/pushpin/ylw-pushpin.png",oo=.5,po=new co({anchor:jo,anchorOrigin:"bottom-left",anchorXUnits:lo,anchorYUnits:ko,crossOrigin:"anonymous",rotation:0,scale:oo,size:mo,src:no}),qo="NO_IMAGE",ro=new tj({color:ho,width:1}),so=new tj({color:[51,51,51,1],width:2}),to=new eo({font:"bold 16px Helvetica",fill:io,stroke:so,scale:.8}),uo=new bl({fill:io,
image:po,text:to,stroke:ro,zIndex:0}),go=[uo]);this.defaultDataProjection=Tb("EPSG:4326");this.a=a.defaultStyle?a.defaultStyle:go;this.c=void 0!==a.extractStyles?a.extractStyles:!0;this.j=void 0!==a.writeStyles?a.writeStyles:!0;this.b={};this.f=void 0!==a.showPointNames?a.showPointNames:!0}var go,ho,io,jo,lo,ko,mo,no,oo,po,qo,ro,so,to,uo;u(fo,Bm);
var vo=["http://www.google.com/kml/ext/2.2"],wo=[null,"http://earth.google.com/kml/2.0","http://earth.google.com/kml/2.1","http://earth.google.com/kml/2.2","http://www.opengis.net/kml/2.2"],xo={fraction:"fraction",pixels:"pixels"};
function yo(a,b){var c,d=[0,0],e="start";a.Y()&&(c=a.Y().ye(),null===c&&(c=mo),2==c.length&&(e=a.Y().c,d[0]=e*c[0]/2,d[1]=-e*c[1]/2,e="left"));if(null!==a.Oa()){var f=a.Oa();c=f.clone();c.ij(f.a||to.a);c.Mi(f.b||to.b);c.mf(f.Ca()||to.Ca());c.nf(f.Da()||so)}else c=to.clone();c.pf(b);c.oj(d[0]);c.pj(d[1]);c.rj(e);return new bl({text:c})}
function zo(a,b,c,d,e){return function(){var f=e,g="";f&&this.U()&&(f="Point"===this.U().S());f&&(g=this.get("name"),f=f&&g);if(a)return f?(f=yo(a[0],g),a.concat(f)):a;if(b){var h=Ao(b,c,d);return f?(f=yo(h[0],g),h.concat(f)):h}return f?(f=yo(c[0],g),c.concat(f)):c}}function Ao(a,b,c){return Array.isArray(a)?a:"string"===typeof a?(!(a in c)&&"#"+a in c&&(a="#"+a),Ao(c[a],b,c)):b}
function Bo(a){a=ll(a,!1);if(a=/^\s*#?\s*([0-9A-Fa-f]{8})\s*$/.exec(a))return a=a[1],[parseInt(a.substr(6,2),16),parseInt(a.substr(4,2),16),parseInt(a.substr(2,2),16),parseInt(a.substr(0,2),16)/255]}function Co(a){a=ll(a,!1);for(var b=[],c=/^\s*([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?)\s*,\s*([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?)(?:\s*,\s*([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?))?\s*/i,d;d=c.exec(a);)b.push(parseFloat(d[1]),parseFloat(d[2]),d[3]?parseFloat(d[3]):0),a=a.substr(d[0].length);if(""===a)return b}
function Do(a){var b=ll(a,!1).trim();return a.baseURI?(new URL(b,a.baseURI)).href:b}function Eo(a){return Jm(a)}function Fo(a,b){return M(null,Go,a,b)}function Ho(a,b){var c=M({B:[],Aj:[]},Io,a,b);if(c){var d=c.B,c=c.Aj,e,f;e=0;for(f=Math.min(d.length,c.length);e<f;++e)d[4*e+3]=c[e];c=new N(null);c.ca("XYZM",d);return c}}function Jo(a,b){var c=M({},Ko,a,b),d=M(null,Lo,a,b);if(d){var e=new N(null);e.ca("XYZ",d);e.H(c);return e}}
function Mo(a,b){var c=M({},Ko,a,b),d=M(null,Lo,a,b);if(d){var e=new F(null);e.ca("XYZ",d,[d.length]);e.H(c);return e}}
function No(a,b){var c=M([],Oo,a,b);if(!c)return null;if(!c.length)return new sm(c);var d,e=!0,f=c[0].S(),g,h,l;h=1;for(l=c.length;h<l;++h)if(g=c[h],g.S()!=f){e=!1;break}if(e)if("Point"==f){d=c[0];e=d.la;f=d.ia();h=1;for(l=c.length;h<l;++h)g=c[h],ha(f,g.ia());d=new P(null);d.ca(e,f);Po(d,c)}else"LineString"==f?(d=new O(null),Nl(d,c),Po(d,c)):"Polygon"==f?(d=new Q(null),Pl(d,c),Po(d,c)):"GeometryCollection"==f?d=new sm(c):sa(!1,37);else d=new sm(c);return d}
function Qo(a,b){var c=M({},Ko,a,b),d=M(null,Lo,a,b);if(d){var e=new E(null);e.ca("XYZ",d);e.H(c);return e}}function Ro(a,b){var c=M({},Ko,a,b),d=M([null],So,a,b);if(d&&d[0]){var e=new F(null),f=d[0],g=[f.length],h,l;h=1;for(l=d.length;h<l;++h)ha(f,d[h]),g.push(f.length);e.ca("XYZ",f,g);e.H(c);return e}}
function To(a,b){var c=M({},Uo,a,b);if(!c)return null;var d="fillStyle"in c?c.fillStyle:io,e=c.fill;void 0===e||e||(d=null);e="imageStyle"in c?c.imageStyle:po;e==qo&&(e=void 0);var f="textStyle"in c?c.textStyle:to,g="strokeStyle"in c?c.strokeStyle:ro,c=c.outline;void 0===c||c||(g=null);return[new bl({fill:d,image:e,stroke:g,text:f,zIndex:void 0})]}
function Po(a,b){var c=b.length,d=Array(b.length),e=Array(b.length),f,g,h,l;h=l=!1;for(g=0;g<c;++g)f=b[g],d[g]=f.get("extrude"),e[g]=f.get("altitudeMode"),h=h||void 0!==d[g],l=l||e[g];h&&a.set("extrude",d);l&&a.set("altitudeMode",e)}function Vo(a,b){Al(Wo,a,b)}function Xo(a,b){Al(Yo,a,b)}
var Zo=L(wo,{displayName:J(R),value:J(R)}),Wo=L(wo,{Data:function(a,b){var c=a.getAttribute("name");Al(Zo,a,b);var d=b[b.length-1];null!==c?d[c]=d.value:null!==d.displayName&&(d[d.displayName]=d.value)},SchemaData:function(a,b){Al($o,a,b)}}),Yo=L(wo,{LatLonAltBox:function(a,b){var c=M({},ap,a,b);if(c){var d=b[b.length-1];d.extent=[parseFloat(c.west),parseFloat(c.south),parseFloat(c.east),parseFloat(c.north)];d.altitudeMode=c.altitudeMode;d.minAltitude=parseFloat(c.minAltitude);d.maxAltitude=parseFloat(c.maxAltitude)}},
Lod:function(a,b){var c=M({},bp,a,b);if(c){var d=b[b.length-1];d.minLodPixels=parseFloat(c.minLodPixels);d.maxLodPixels=parseFloat(c.maxLodPixels);d.minFadeExtent=parseFloat(c.minFadeExtent);d.maxFadeExtent=parseFloat(c.maxFadeExtent)}}}),ap=L(wo,{altitudeMode:J(R),minAltitude:J(Jm),maxAltitude:J(Jm),north:J(Jm),south:J(Jm),east:J(Jm),west:J(Jm)}),bp=L(wo,{minLodPixels:J(Jm),maxLodPixels:J(Jm),minFadeExtent:J(Jm),maxFadeExtent:J(Jm)}),Ko=L(wo,{extrude:J(Gm),altitudeMode:J(R)}),Go=L(wo,{coordinates:tl(Co)}),
So=L(wo,{innerBoundaryIs:function(a,b){var c=M(void 0,cp,a,b);c&&b[b.length-1].push(c)},outerBoundaryIs:function(a,b){var c=M(void 0,dp,a,b);c&&(b[b.length-1][0]=c)}}),Io=L(wo,{when:function(a,b){var c=b[b.length-1].Aj,d=ll(a,!1),d=Date.parse(d);c.push(isNaN(d)?0:d)}},L(vo,{coord:function(a,b){var c=b[b.length-1].B,d=ll(a,!1);(d=/^\s*([+\-]?\d+(?:\.\d*)?(?:e[+\-]?\d*)?)\s+([+\-]?\d+(?:\.\d*)?(?:e[+\-]?\d*)?)\s+([+\-]?\d+(?:\.\d*)?(?:e[+\-]?\d*)?)\s*$/i.exec(d))?c.push(parseFloat(d[1]),parseFloat(d[2]),
parseFloat(d[3]),0):c.push(0,0,0,0)}})),Lo=L(wo,{coordinates:tl(Co)}),ep=L(wo,{href:J(Do)},L(vo,{x:J(Jm),y:J(Jm),w:J(Jm),h:J(Jm)})),fp=L(wo,{Icon:J(function(a,b){var c=M({},ep,a,b);return c?c:null}),heading:J(Jm),hotSpot:J(function(a){var b=a.getAttribute("xunits"),c=a.getAttribute("yunits");return{x:parseFloat(a.getAttribute("x")),Pg:xo[b],y:parseFloat(a.getAttribute("y")),Qg:xo[c]}}),scale:J(Eo)}),cp=L(wo,{LinearRing:tl(Fo)}),gp=L(wo,{color:J(Bo),scale:J(Eo)}),hp=L(wo,{color:J(Bo),width:J(Jm)}),
Oo=L(wo,{LineString:sl(Jo),LinearRing:sl(Mo),MultiGeometry:sl(No),Point:sl(Qo),Polygon:sl(Ro)}),ip=L(vo,{Track:sl(Ho)}),kp=L(wo,{ExtendedData:Vo,Region:Xo,Link:function(a,b){Al(jp,a,b)},address:J(R),description:J(R),name:J(R),open:J(Gm),phoneNumber:J(R),visibility:J(Gm)}),jp=L(wo,{href:J(Do)}),dp=L(wo,{LinearRing:tl(Fo)}),lp=L(wo,{Style:J(To),key:J(R),styleUrl:J(Do)}),np=L(wo,{ExtendedData:Vo,Region:Xo,MultiGeometry:J(No,"geometry"),LineString:J(Jo,"geometry"),LinearRing:J(Mo,"geometry"),Point:J(Qo,
"geometry"),Polygon:J(Ro,"geometry"),Style:J(To),StyleMap:function(a,b){var c=M(void 0,mp,a,b);if(c){var d=b[b.length-1];Array.isArray(c)?d.Style=c:"string"===typeof c?d.styleUrl=c:sa(!1,38)}},address:J(R),description:J(R),name:J(R),open:J(Gm),phoneNumber:J(R),styleUrl:J(Do),visibility:J(Gm)},L(vo,{MultiTrack:J(function(a,b){var c=M([],ip,a,b);if(c){var d=new O(null);Nl(d,c);return d}},"geometry"),Track:J(Ho,"geometry")})),op=L(wo,{color:J(Bo),fill:J(Gm),outline:J(Gm)}),$o=L(wo,{SimpleData:function(a,
b){var c=a.getAttribute("name");if(null!==c){var d=R(a);b[b.length-1][c]=d}}}),Uo=L(wo,{IconStyle:function(a,b){var c=M({},fp,a,b);if(c){var d=b[b.length-1],e="Icon"in c?c.Icon:{},f=!("Icon"in c)||0<Object.keys(e).length,g,h=e.href;h?g=h:f&&(g=no);var l,m,n;(h=c.hotSpot)?(l=[h.x,h.y],m=h.Pg,n=h.Qg):g===no?(l=jo,m=lo,n=ko):/^http:\/\/maps\.(?:google|gstatic)\.com\//.test(g)&&(l=[.5,0],n=m="fraction");var p,h=e.x,q=e.y;void 0!==h&&void 0!==q&&(p=[h,q]);var r,h=e.w,e=e.h;void 0!==h&&void 0!==e&&(r=[h,
e]);var v,e=c.heading;void 0!==e&&(v=Ca(e));c=c.scale;f?(g==no&&(r=mo,void 0===c&&(c=oo)),f=new co({anchor:l,anchorOrigin:"bottom-left",anchorXUnits:m,anchorYUnits:n,crossOrigin:"anonymous",offset:p,offsetOrigin:"bottom-left",rotation:v,scale:c,size:r,src:g}),d.imageStyle=f):d.imageStyle=qo}},LabelStyle:function(a,b){var c=M({},gp,a,b);c&&(b[b.length-1].textStyle=new eo({fill:new al({color:"color"in c?c.color:ho}),scale:c.scale}))},LineStyle:function(a,b){var c=M({},hp,a,b);c&&(b[b.length-1].strokeStyle=
new tj({color:"color"in c?c.color:ho,width:"width"in c?c.width:1}))},PolyStyle:function(a,b){var c=M({},op,a,b);if(c){var d=b[b.length-1];d.fillStyle=new al({color:"color"in c?c.color:ho});var e=c.fill;void 0!==e&&(d.fill=e);c=c.outline;void 0!==c&&(d.outline=c)}}}),mp=L(wo,{Pair:function(a,b){var c=M({},lp,a,b);if(c){var d=c.key;d&&"normal"==d&&((d=c.styleUrl)&&(b[b.length-1]=d),(c=c.Style)&&(b[b.length-1]=c))}}});k=fo.prototype;
k.pg=function(a,b){var c=L(wo,{Document:rl(this.pg,this),Folder:rl(this.pg,this),Placemark:sl(this.xg,this),Style:this.zp.bind(this),StyleMap:this.yp.bind(this)});if(c=M([],c,a,b,this))return c};k.xg=function(a,b){var c=M({geometry:null},np,a,b);if(c){var d=new I,e=a.getAttribute("id");null!==e&&d.lc(e);var e=b[0],f=c.geometry;f&&Hl(f,!1,e);d.Ta(f);delete c.geometry;this.c&&d.cg(zo(c.Style,c.styleUrl,this.a,this.b,this.f));delete c.Style;d.H(c);return d}};
k.zp=function(a,b){var c=a.getAttribute("id");if(null!==c){var d=To(a,b);d&&(c=a.baseURI?(new URL("#"+c,a.baseURI)).href:"#"+c,this.b[c]=d)}};k.yp=function(a,b){var c=a.getAttribute("id");if(null!==c){var d=M(void 0,mp,a,b);d&&(c=a.baseURI?(new URL("#"+c,a.baseURI)).href:"#"+c,this.b[c]=d)}};k.rg=function(a,b){if(!fa(wo,a.namespaceURI))return null;var c=this.xg(a,[Fl(this,a,b)]);return c?c:null};
k.Bc=function(a,b){if(!fa(wo,a.namespaceURI))return[];var c;c=a.localName;if("Document"==c||"Folder"==c)return(c=this.pg(a,[Fl(this,a,b)]))?c:[];if("Placemark"==c)return(c=this.xg(a,[Fl(this,a,b)]))?[c]:[];if("kml"==c){c=[];var d;for(d=a.firstElementChild;d;d=d.nextElementSibling){var e=this.Bc(d,b);e&&ha(c,e)}return c}return[]};k.sp=function(a){if(nl(a))return pp(this,a);if(pl(a))return qp(this,a);if("string"===typeof a)return a=ql(a),pp(this,a)};
function pp(a,b){var c;for(c=b.firstChild;c;c=c.nextSibling)if(c.nodeType==Node.ELEMENT_NODE){var d=qp(a,c);if(d)return d}}function qp(a,b){var c;for(c=b.firstElementChild;c;c=c.nextElementSibling)if(fa(wo,c.namespaceURI)&&"name"==c.localName)return R(c);for(c=b.firstElementChild;c;c=c.nextElementSibling){var d=c.localName;if(fa(wo,c.namespaceURI)&&("Document"==d||"Folder"==d||"Placemark"==d||"kml"==d)&&(d=qp(a,c)))return d}}
k.tp=function(a){var b=[];nl(a)?ha(b,rp(this,a)):pl(a)?ha(b,sp(this,a)):"string"===typeof a&&(a=ql(a),ha(b,rp(this,a)));return b};function rp(a,b){var c,d=[];for(c=b.firstChild;c;c=c.nextSibling)c.nodeType==Node.ELEMENT_NODE&&ha(d,sp(a,c));return d}
function sp(a,b){var c,d=[];for(c=b.firstElementChild;c;c=c.nextElementSibling)if(fa(wo,c.namespaceURI)&&"NetworkLink"==c.localName){var e=M({},kp,c,[]);d.push(e)}for(c=b.firstElementChild;c;c=c.nextElementSibling)e=c.localName,!fa(wo,c.namespaceURI)||"Document"!=e&&"Folder"!=e&&"kml"!=e||ha(d,sp(a,c));return d}k.wp=function(a){var b=[];nl(a)?ha(b,tp(this,a)):pl(a)?ha(b,this.jf(a)):"string"===typeof a&&(a=ql(a),ha(b,tp(this,a)));return b};
function tp(a,b){var c,d=[];for(c=b.firstChild;c;c=c.nextSibling)c.nodeType==Node.ELEMENT_NODE&&ha(d,a.jf(c));return d}k.jf=function(a){var b,c=[];for(b=a.firstElementChild;b;b=b.nextElementSibling)if(fa(wo,b.namespaceURI)&&"Region"==b.localName){var d=M({},Yo,b,[]);c.push(d)}for(b=a.firstElementChild;b;b=b.nextElementSibling)a=b.localName,!fa(wo,b.namespaceURI)||"Document"!=a&&"Folder"!=a&&"kml"!=a||ha(c,this.jf(b));return c};
function up(a,b){var c=bd(b),c=[255*(4==c.length?c[3]:1),c[2],c[1],c[0]],d;for(d=0;4>d;++d){var e=parseInt(c[d],10).toString(16);c[d]=1==e.length?"0"+e:e}Om(a,c.join(""))}function vp(a,b,c){a={node:a};var d=b.S(),e,f;"GeometryCollection"==d?(e=b.Qf(),f=wp):"MultiPoint"==d?(e=b.Zd(),f=xp):"MultiLineString"==d?(e=b.Nc(),f=yp):"MultiPolygon"==d?(e=b.md(),f=zp):sa(!1,39);Bl(a,Ap,f,e,c)}function Bp(a,b,c){Bl({node:a},Cp,Dp,[b],c)}
function Ep(a,b,c){var d={node:a};b.a&&a.setAttribute("id",b.a);a=b.M();var e={address:1,description:1,name:1,open:1,phoneNumber:1,styleUrl:1,visibility:1};e[b.c]=1;var f=Object.keys(a||{}).sort().filter(function(a){return!e[a]});if(0<f.length){var g=zl(a,f);Bl(d,Fp,Gp,[{names:f,values:g}],c)}if(f=b.Rc())if(f=f.call(b,0))f=Array.isArray(f)?f[0]:f,this.j&&(a.Style=f),(f=f.Oa())&&(a.name=f.Oa());f=Hp[c[c.length-1].node.namespaceURI];a=zl(a,f);Bl(d,Fp,yl,a,c,f);a=c[0];(b=b.U())&&(b=Hl(b,!0,a));Bl(d,
Fp,wp,[b],c)}function Ip(a,b,c){var d=b.ia();a={node:a};a.layout=b.la;a.stride=b.sa();Bl(a,Jp,Kp,[d],c)}function Lp(a,b,c){b=b.Oc();var d=b.shift();a={node:a};Bl(a,Mp,Np,b,c);Bl(a,Mp,Op,[d],c)}function Pp(a,b){Pm(a,Math.round(1E6*b)/1E6)}
var Qp=L(wo,["Document","Placemark"]),Tp=L(wo,{Document:K(function(a,b,c){Bl({node:a},Rp,Sp,b,c,void 0,this)}),Placemark:K(Ep)}),Rp=L(wo,{Placemark:K(Ep)}),Up=L(wo,{Data:K(function(a,b,c){a.setAttribute("name",b.name);a={node:a};b=b.value;"object"==typeof b?(null!==b&&b.displayName&&Bl(a,Up,yl,[b.displayName],c,["displayName"]),null!==b&&b.value&&Bl(a,Up,yl,[b.value],c,["value"])):Bl(a,Up,yl,[b],c,["value"])}),value:K(function(a,b){Om(a,b)}),displayName:K(function(a,b){a.appendChild(il.createCDATASection(b))})}),
Vp={Point:"Point",LineString:"LineString",LinearRing:"LinearRing",Polygon:"Polygon",MultiPoint:"MultiGeometry",MultiLineString:"MultiGeometry",MultiPolygon:"MultiGeometry",GeometryCollection:"MultiGeometry"},Wp=L(wo,["href"],L(vo,["x","y","w","h"])),Xp=L(wo,{href:K(Om)},L(vo,{x:K(Pm),y:K(Pm),w:K(Pm),h:K(Pm)})),Yp=L(wo,["scale","heading","Icon","hotSpot"]),$p=L(wo,{Icon:K(function(a,b,c){a={node:a};var d=Wp[c[c.length-1].node.namespaceURI],e=zl(b,d);Bl(a,Xp,yl,e,c,d);d=Wp[vo[0]];e=zl(b,d);Bl(a,Xp,
Zp,e,c,d)}),heading:K(Pm),hotSpot:K(function(a,b){a.setAttribute("x",b.x);a.setAttribute("y",b.y);a.setAttribute("xunits",b.Pg);a.setAttribute("yunits",b.Qg)}),scale:K(Pp)}),aq=L(wo,["color","scale"]),bq=L(wo,{color:K(up),scale:K(Pp)}),cq=L(wo,["color","width"]),dq=L(wo,{color:K(up),width:K(Pm)}),Cp=L(wo,{LinearRing:K(Ip)}),Ap=L(wo,{LineString:K(Ip),Point:K(Ip),Polygon:K(Lp),GeometryCollection:K(vp)}),Hp=L(wo,"name open visibility address phoneNumber description styleUrl Style".split(" ")),Fp=L(wo,
{ExtendedData:K(function(a,b,c){a={node:a};var d=b.names;b=b.values;for(var e=d.length,f=0;f<e;f++)Bl(a,Up,eq,[{name:d[f],value:b[f]}],c)}),MultiGeometry:K(vp),LineString:K(Ip),LinearRing:K(Ip),Point:K(Ip),Polygon:K(Lp),Style:K(function(a,b,c){a={node:a};var d={},e=b.Ca(),f=b.Da(),g=b.Y();b=b.Oa();g instanceof co&&(d.IconStyle=g);b&&(d.LabelStyle=b);f&&(d.LineStyle=f);e&&(d.PolyStyle=e);b=fq[c[c.length-1].node.namespaceURI];d=zl(d,b);Bl(a,gq,yl,d,c,b)}),address:K(Om),description:K(Om),name:K(Om),
open:K(Nm),phoneNumber:K(Om),styleUrl:K(Om),visibility:K(Nm)}),Jp=L(wo,{coordinates:K(function(a,b,c){c=c[c.length-1];var d=c.layout;c=c.stride;var e;"XY"==d||"XYM"==d?e=2:"XYZ"==d||"XYZM"==d?e=3:sa(!1,34);var f,g=b.length,h="";if(0<g){h+=b[0];for(d=1;d<e;++d)h+=","+b[d];for(f=c;f<g;f+=c)for(h+=" "+b[f],d=1;d<e;++d)h+=","+b[f+d]}Om(a,h)})}),Mp=L(wo,{outerBoundaryIs:K(Bp),innerBoundaryIs:K(Bp)}),hq=L(wo,{color:K(up)}),fq=L(wo,["IconStyle","LabelStyle","LineStyle","PolyStyle"]),gq=L(wo,{IconStyle:K(function(a,
b,c){a={node:a};var d={},e=b.kc(),f=b.ye(),g={href:b.b.l};if(e){g.w=e[0];g.h=e[1];var h=b.Jc(),l=b.Tc();l&&f&&l[0]&&l[1]!==e[1]&&(g.x=l[0],g.y=f[1]-(l[1]+e[1]));h&&h[0]&&h[1]!==e[1]&&(d.hotSpot={x:h[0],Pg:"pixels",y:e[1]-h[1],Qg:"pixels"})}d.Icon=g;e=b.c;1!==e&&(d.scale=e);(b=b.j)&&(d.heading=b);b=Yp[c[c.length-1].node.namespaceURI];d=zl(d,b);Bl(a,$p,yl,d,c,b)}),LabelStyle:K(function(a,b,c){a={node:a};var d={},e=b.Ca();e&&(d.color=e.b);(b=b.b)&&1!==b&&(d.scale=b);b=aq[c[c.length-1].node.namespaceURI];
d=zl(d,b);Bl(a,bq,yl,d,c,b)}),LineStyle:K(function(a,b,c){a={node:a};var d=cq[c[c.length-1].node.namespaceURI];b=zl({color:b.a,width:b.c},d);Bl(a,dq,yl,b,c,d)}),PolyStyle:K(function(a,b,c){Bl({node:a},hq,iq,[b.b],c)})});function Zp(a,b,c){return kl(vo[0],"gx:"+c)}function Sp(a,b){return kl(b[b.length-1].node.namespaceURI,"Placemark")}function wp(a,b){if(a)return kl(b[b.length-1].node.namespaceURI,Vp[a.S()])}
var iq=wl("color"),Kp=wl("coordinates"),eq=wl("Data"),Gp=wl("ExtendedData"),Np=wl("innerBoundaryIs"),xp=wl("Point"),yp=wl("LineString"),Dp=wl("LinearRing"),zp=wl("Polygon"),Op=wl("outerBoundaryIs");
fo.prototype.Zb=function(a,b){b=Gl(this,b);var c=kl(wo[4],"kml");c.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:gx",vo[0]);c.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xsi","http://www.w3.org/2001/XMLSchema-instance");c.setAttributeNS("http://www.w3.org/2001/XMLSchema-instance","xsi:schemaLocation","http://www.opengis.net/kml/2.2 https://developers.google.com/kml/schema/kml22gx.xsd");var d={node:c},e={};1<a.length?e.Document=a:1==a.length&&(e.Placemark=a[0]);var f=Qp[c.namespaceURI],
e=zl(e,f);Bl(d,Tp,yl,e,[b],f,this);return c};(function(){var a={},b={ma:a};(function(c){if("object"===typeof a&&"undefined"!==typeof b)b.ma=c();else{var d;"undefined"!==typeof window?d=window:"undefined"!==typeof global?d=global:"undefined"!==typeof self?d=self:d=this;d.Bq=c()}})(function(){return function d(a,b,g){function e(h,l){if(!b[h]){if(!a[h]){var m="function"==typeof require&&require;if(!l&&m)return m(h,!0);if(f)return f(h,!0);m=Error("Cannot find module '"+h+"'");throw m.code="MODULE_NOT_FOUND",m;}m=b[h]={ma:{}};a[h][0].call(m.ma,function(b){var d=
a[h][1][b];return e(d?d:b)},m,m.ma,d,a,b,g)}return b[h].ma}for(var f="function"==typeof require&&require,m=0;m<g.length;m++)e(g[m]);return e}({1:[function(a,b,f){f.read=function(a,b,d,e,f){var g;g=8*f-e-1;var h=(1<<g)-1,l=h>>1,m=-7;f=d?f-1:0;var n=d?-1:1,y=a[b+f];f+=n;d=y&(1<<-m)-1;y>>=-m;for(m+=g;0<m;d=256*d+a[b+f],f+=n,m-=8);g=d&(1<<-m)-1;d>>=-m;for(m+=e;0<m;g=256*g+a[b+f],f+=n,m-=8);if(0===d)d=1-l;else{if(d===h)return g?NaN:Infinity*(y?-1:1);g+=Math.pow(2,e);d-=l}return(y?-1:1)*g*Math.pow(2,d-
e)};f.write=function(a,b,d,e,f,p){var g,h=8*p-f-1,l=(1<<h)-1,m=l>>1,n=23===f?Math.pow(2,-24)-Math.pow(2,-77):0;p=e?0:p-1;var A=e?1:-1,B=0>b||0===b&&0>1/b?1:0;b=Math.abs(b);isNaN(b)||Infinity===b?(b=isNaN(b)?1:0,e=l):(e=Math.floor(Math.log(b)/Math.LN2),1>b*(g=Math.pow(2,-e))&&(e--,g*=2),b=1<=e+m?b+n/g:b+n*Math.pow(2,1-m),2<=b*g&&(e++,g/=2),e+m>=l?(b=0,e=l):1<=e+m?(b=(b*g-1)*Math.pow(2,f),e+=m):(b=b*Math.pow(2,m-1)*Math.pow(2,f),e=0));for(;8<=f;a[d+p]=b&255,p+=A,b/=256,f-=8);e=e<<f|b;for(h+=f;0<h;a[d+
p]=e&255,p+=A,e/=256,h-=8);a[d+p-A]|=128*B}},{}],2:[function(a,b){function d(a){this.nc=ArrayBuffer.isView&&ArrayBuffer.isView(a)?a:new Uint8Array(a||0);this.type=this.ha=0;this.length=this.nc.length}function e(a,b,d){var e=d.nc,f,g;g=e[d.ha++];f=(g&112)>>4;if(128>g)return h(a,f,b);g=e[d.ha++];f|=(g&127)<<3;if(128>g)return h(a,f,b);g=e[d.ha++];f|=(g&127)<<10;if(128>g)return h(a,f,b);g=e[d.ha++];f|=(g&127)<<17;if(128>g)return h(a,f,b);g=e[d.ha++];f|=(g&127)<<24;if(128>g)return h(a,f,b);g=e[d.ha++];
if(128>g)return h(a,f|(g&1)<<31,b);throw Error("Expected varint not more than 10 bytes");}function h(a,b,d){return d?4294967296*b+(a>>>0):4294967296*(b>>>0)+(a>>>0)}b.ma=d;var l=a("ieee754");d.c=0;d.g=1;d.b=2;d.a=5;d.prototype={ug:function(a,b,d){for(d=d||this.length;this.ha<d;){var e=this.Ma(),f=e>>3,g=this.ha;this.type=e&7;a(f,b,this);this.ha===g&&this.bq(e)}return b},op:function(){var a=l.read(this.nc,this.ha,!0,23,4);this.ha+=4;return a},kp:function(){var a=l.read(this.nc,this.ha,!0,52,8);this.ha+=
8;return a},Ma:function(a){var b=this.nc,d,f;f=b[this.ha++];d=f&127;if(128>f)return d;f=b[this.ha++];d|=(f&127)<<7;if(128>f)return d;f=b[this.ha++];d|=(f&127)<<14;if(128>f)return d;f=b[this.ha++];d|=(f&127)<<21;if(128>f)return d;f=b[this.ha];return e(d|(f&15)<<28,a,this)},Ap:function(){return this.Ma(!0)},be:function(){var a=this.Ma();return 1===a%2?(a+1)/-2:a/2},ip:function(){return!!this.Ma()},Ag:function(){for(var a=this.Ma()+this.ha,b=this.nc,d="",e=this.ha;e<a;){var f=b[e],g=null,h=239<f?4:223<
f?3:191<f?2:1;if(e+h>a)break;var l,A,B;if(1===h)128>f&&(g=f);else if(2===h)l=b[e+1],128===(l&192)&&(g=(f&31)<<6|l&63,127>=g&&(g=null));else if(3===h){if(l=b[e+1],A=b[e+2],128===(l&192)&&128===(A&192)&&(g=(f&15)<<12|(l&63)<<6|A&63,2047>=g||55296<=g&&57343>=g))g=null}else 4===h&&(l=b[e+1],A=b[e+2],B=b[e+3],128===(l&192)&&128===(A&192)&&128===(B&192)&&(g=(f&15)<<18|(l&63)<<12|(A&63)<<6|B&63,65535>=g||1114112<=g))&&(g=null);null===g?(g=65533,h=1):65535<g&&(g-=65536,d+=String.fromCharCode(g>>>10&1023|
55296),g=56320|g&1023);d+=String.fromCharCode(g);e+=h}this.ha=a;return d},bq:function(a){a&=7;if(a===d.c)for(;127<this.nc[this.ha++];);else if(a===d.b)this.ha=this.Ma()+this.ha;else if(a===d.a)this.ha+=4;else if(a===d.g)this.ha+=8;else throw Error("Unimplemented type: "+a);}}},{ieee754:1}]},{},[2])(2)});Dj=b.ma})();(function(){var a={},b={ma:a};(function(c){if("object"===typeof a&&"undefined"!==typeof b)b.ma=c();else{var d;"undefined"!==typeof window?d=window:"undefined"!==typeof global?d=global:"undefined"!==typeof self?d=self:d=this;d.Eq=c()}})(function(){return function d(a,b,g){function e(h,l){if(!b[h]){if(!a[h]){var m="function"==typeof require&&require;if(!l&&m)return m(h,!0);if(f)return f(h,!0);m=Error("Cannot find module '"+h+"'");throw m.code="MODULE_NOT_FOUND",m;}m=b[h]={ma:{}};a[h][0].call(m.ma,function(b){var d=
a[h][1][b];return e(d?d:b)},m,m.ma,d,a,b,g)}return b[h].ma}for(var f="function"==typeof require&&require,m=0;m<g.length;m++)e(g[m]);return e}({1:[function(a,b){function d(a,b){this.x=a;this.y=b}b.ma=d;d.prototype={clone:function(){return new d(this.x,this.y)},add:function(a){return this.clone().Uj(a)},rotate:function(a){return this.clone().dk(a)},round:function(){return this.clone().ek()},angle:function(){return Math.atan2(this.y,this.x)},Uj:function(a){this.x+=a.x;this.y+=a.y;return this},dk:function(a){var b=
Math.cos(a);a=Math.sin(a);var d=a*this.x+b*this.y;this.x=b*this.x-a*this.y;this.y=d;return this},ek:function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this}};d.b=function(a){return a instanceof d?a:Array.isArray(a)?new d(a[0],a[1]):a}},{}],2:[function(a,b){b.ma.Tj=a("./lib/vectortile.js");b.ma.yq=a("./lib/vectortilefeature.js");b.ma.zq=a("./lib/vectortilelayer.js")},{"./lib/vectortile.js":3,"./lib/vectortilefeature.js":4,"./lib/vectortilelayer.js":5}],3:[function(a,b){function d(a,
b,d){3===a&&(a=new e(d,d.Ma()+d.ha),a.length&&(b[a.name]=a))}var e=a("./vectortilelayer");b.ma=function(a,b){this.layers=a.ug(d,{},b)}},{"./vectortilelayer":5}],4:[function(a,b){function d(a,b,d,f,g){this.properties={};this.extent=d;this.type=0;this.Ec=a;this.Af=-1;this.ne=f;this.pe=g;a.ug(e,this,b)}function e(a,b,d){if(1==a)b.id=d.Ma();else if(2==a)for(a=d.Ma()+d.ha;d.ha<a;){var e=b.ne[d.Ma()],f=b.pe[d.Ma()];b.properties[e]=f}else 3==a?b.type=d.Ma():4==a&&(b.Af=d.ha)}var h=a("point-geometry");b.ma=
d;d.b=["Unknown","Point","LineString","Polygon"];d.prototype.Hh=function(){var a=this.Ec;a.ha=this.Af;for(var b=a.Ma()+a.ha,d=1,e=0,f=0,g=0,v=[],x;a.ha<b;)if(e||(e=a.Ma(),d=e&7,e>>=3),e--,1===d||2===d)f+=a.be(),g+=a.be(),1===d&&(x&&v.push(x),x=[]),x.push(new h(f,g));else if(7===d)x&&x.push(x[0].clone());else throw Error("unknown command "+d);x&&v.push(x);return v};d.prototype.bbox=function(){var a=this.Ec;a.ha=this.Af;for(var b=a.Ma()+a.ha,d=1,e=0,f=0,g=0,h=Infinity,x=-Infinity,y=Infinity,A=-Infinity;a.ha<
b;)if(e||(e=a.Ma(),d=e&7,e>>=3),e--,1===d||2===d)f+=a.be(),g+=a.be(),f<h&&(h=f),f>x&&(x=f),g<y&&(y=g),g>A&&(A=g);else if(7!==d)throw Error("unknown command "+d);return[h,y,x,A]}},{"point-geometry":1}],5:[function(a,b){function d(a,b){this.version=1;this.name=null;this.extent=4096;this.length=0;this.Ec=a;this.ne=[];this.pe=[];this.me=[];a.ug(e,this,b);this.length=this.me.length}function e(a,b,d){15===a?b.version=d.Ma():1===a?b.name=d.Ag():5===a?b.extent=d.Ma():2===a?b.me.push(d.ha):3===a?b.ne.push(d.Ag()):
4===a&&b.pe.push(h(d))}function h(a){for(var b=null,d=a.Ma()+a.ha;a.ha<d;)b=a.Ma()>>3,b=1===b?a.Ag():2===b?a.op():3===b?a.kp():4===b?a.Ap():5===b?a.Ma():6===b?a.be():7===b?a.ip():null;return b}var l=a("./vectortilefeature.js");b.ma=d;d.prototype.feature=function(a){if(0>a||a>=this.me.length)throw Error("feature index out of bounds");this.Ec.ha=this.me[a];a=this.Ec.Ma()+this.Ec.ha;return new l(this.Ec,a,this.extent,this.ne,this.pe)}},{"./vectortilefeature.js":4}]},{},[2])(2)});Ej=b.ma})();function jq(a,b,c,d){this.g=a;this.b=b;this.i=c;this.c=d}k=jq.prototype;k.get=function(a){return this.c[a]};k.Sb=function(){return this.i};k.D=function(){this.a||(this.a="Point"===this.g?Xa(this.b):Ya(this.b,0,this.b.length,2));return this.a};k.gc=function(){return this.b};k.ia=jq.prototype.gc;k.U=function(){return this};k.Nn=function(){return this.c};k.Td=jq.prototype.U;k.sa=function(){return 2};k.Rc=oa;k.S=function(){return this.g};function kq(a){El.call(this);a=a?a:{};this.defaultDataProjection=new zb({code:"",units:"tile-pixels"});this.b=a.featureClass?a.featureClass:jq;this.g=a.geometryName;this.a=a.layerName?a.layerName:"layer";this.c=a.layers?a.layers:null}u(kq,El);k=kq.prototype;k.S=function(){return"arraybuffer"};
k.Pa=function(a,b){var c=this.c,d=new Dj(a),d=new Ej.Tj(d),e=[],f=this.b,g,h,l;for(l in d.layers)if(!c||-1!=c.indexOf(l)){g=d.layers[l];for(var m=0,n=g.length;m<n;++m){if(f===jq){h=void 0;var p=g.feature(m),q=l,r=p.Hh(),v=[],x=[];lq(r,x,v);var y=p.type;1===y?h=1===r.length?"Point":"MultiPoint":2===y?h=1===r.length?"LineString":"MultiLineString":3===y&&(h="Polygon");p=p.properties;p[this.a]=q;h=new this.b(h,x,v,p)}else{y=g.feature(m);p=l;x=b;h=new this.b;q=y.id;v=y.properties;v[this.a]=p;this.g&&h.Yc(this.g);
p=void 0;r=y.type;if(0===r)p=null;else{var y=y.Hh(),A=[],B=[];lq(y,B,A);1===r?p=1===y.length?new E(null):new P(null):2===r?1===y.length?p=new N(null):p=new O(null):3===r&&(p=new F(null));p.ca("XY",B,A)}x=Hl(p,!1,Gl(this,x));h.Ta(x);h.lc(q);h.H(v)}e.push(h)}}return e};k.jb=function(){return this.defaultDataProjection};k.fn=function(a){this.c=a};function lq(a,b,c){for(var d=0,e=0,f=a.length;e<f;++e){var g=a[e],h,l;h=0;for(l=g.length;h<l;++h){var m=g[h];b.push(m.x,m.y)}d+=2*h;c.push(d)}}k.Vb=function(){};
k.Xc=function(){};k.Dd=function(){};k.ed=function(){};k.Yb=function(){};function mq(){Bm.call(this);this.defaultDataProjection=Tb("EPSG:4326")}u(mq,Bm);function nq(a,b){b[b.length-1].ee[a.getAttribute("k")]=a.getAttribute("v")}
var oq=[null],pq=L(oq,{nd:function(a,b){b[b.length-1].qd.push(a.getAttribute("ref"))},tag:nq}),rq=L(oq,{node:function(a,b){var c=b[0],d=b[b.length-1],e=a.getAttribute("id"),f=[parseFloat(a.getAttribute("lon")),parseFloat(a.getAttribute("lat"))];d.Lh[e]=f;var g=M({ee:{}},qq,a,b);tb(g.ee)||(f=new E(f),Hl(f,!1,c),c=new I(f),c.lc(e),c.H(g.ee),d.features.push(c))},way:function(a,b){for(var c=b[0],d=a.getAttribute("id"),e=M({qd:[],ee:{}},pq,a,b),f=b[b.length-1],g=[],h=0,l=e.qd.length;h<l;h++)ha(g,f.Lh[e.qd[h]]);
e.qd[0]==e.qd[e.qd.length-1]?(h=new F(null),h.ca("XY",g,[g.length])):(h=new N(null),h.ca("XY",g));Hl(h,!1,c);c=new I(h);c.lc(d);c.H(e.ee);f.features.push(c)}}),qq=L(oq,{tag:nq});mq.prototype.Bc=function(a,b){var c=Fl(this,a,b);return"osm"==a.localName&&(c=M({Lh:{},features:[]},rq,a,[c]),c.features)?c.features:[]};mq.prototype.Ng=function(){};mq.prototype.Zb=function(){};mq.prototype.he=function(){};function tq(a){return a.getAttributeNS("http://www.w3.org/1999/xlink","href")};function uq(){}uq.prototype.read=function(a){return nl(a)?this.a(a):pl(a)?this.b(a):"string"===typeof a?(a=ql(a),this.a(a)):null};function vq(){}u(vq,uq);vq.prototype.a=function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType==Node.ELEMENT_NODE)return this.b(a);return null};vq.prototype.b=function(a){return(a=M({},wq,a,[]))?a:null};
var xq=[null,"http://www.opengis.net/ows/1.1"],wq=L(xq,{ServiceIdentification:J(function(a,b){return M({},yq,a,b)}),ServiceProvider:J(function(a,b){return M({},zq,a,b)}),OperationsMetadata:J(function(a,b){return M({},Aq,a,b)})}),Bq=L(xq,{DeliveryPoint:J(R),City:J(R),AdministrativeArea:J(R),PostalCode:J(R),Country:J(R),ElectronicMailAddress:J(R)}),Cq=L(xq,{Value:ul(function(a){return R(a)})}),Dq=L(xq,{AllowedValues:J(function(a,b){return M({},Cq,a,b)})}),Fq=L(xq,{Phone:J(function(a,b){return M({},
Eq,a,b)}),Address:J(function(a,b){return M({},Bq,a,b)})}),Hq=L(xq,{HTTP:J(function(a,b){return M({},Gq,a,b)})}),Gq=L(xq,{Get:ul(function(a,b){var c=tq(a);if(c)return M({href:c},Iq,a,b)}),Post:void 0}),Jq=L(xq,{DCP:J(function(a,b){return M({},Hq,a,b)})}),Aq=L(xq,{Operation:function(a,b){var c=a.getAttribute("name"),d=M({},Jq,a,b);d&&(b[b.length-1][c]=d)}}),Eq=L(xq,{Voice:J(R),Facsimile:J(R)}),Iq=L(xq,{Constraint:ul(function(a,b){var c=a.getAttribute("name");if(c)return M({name:c},Dq,a,b)})}),Kq=L(xq,
{IndividualName:J(R),PositionName:J(R),ContactInfo:J(function(a,b){return M({},Fq,a,b)})}),yq=L(xq,{Title:J(R),ServiceTypeVersion:J(R),ServiceType:J(R)}),zq=L(xq,{ProviderName:J(R),ProviderSite:J(tq),ServiceContact:J(function(a,b){return M({},Kq,a,b)})});function Lq(a,b,c,d){var e;void 0!==d?e=d:e=[];for(var f=d=0;f<b;){var g=a[f++];e[d++]=a[f++];e[d++]=g;for(g=2;g<c;++g)e[d++]=a[f++]}e.length=d};function Mq(a){a=a?a:{};El.call(this);this.defaultDataProjection=Tb("EPSG:4326");this.b=a.factor?a.factor:1E5;this.a=a.geometryLayout?a.geometryLayout:"XY"}u(Mq,Un);function Nq(a,b,c){var d,e=Array(b);for(d=0;d<b;++d)e[d]=0;var f,g;f=0;for(g=a.length;f<g;)for(d=0;d<b;++d,++f){var h=a[f],l=h-e[d];e[d]=h;a[f]=l}return Oq(a,c?c:1E5)}function Pq(a,b,c){var d,e=Array(b);for(d=0;d<b;++d)e[d]=0;a=Qq(a,c?c:1E5);var f;c=0;for(f=a.length;c<f;)for(d=0;d<b;++d,++c)e[d]+=a[c],a[c]=e[d];return a}
function Oq(a,b){var c=b?b:1E5,d,e;d=0;for(e=a.length;d<e;++d)a[d]=Math.round(a[d]*c);c=0;for(d=a.length;c<d;++c)e=a[c],a[c]=0>e?~(e<<1):e<<1;c="";d=0;for(e=a.length;d<e;++d){for(var f,g=a[d],h="";32<=g;)f=(32|g&31)+63,h+=String.fromCharCode(f),g>>=5;h+=String.fromCharCode(g+63);c+=h}return c}
function Qq(a,b){var c=b?b:1E5,d=[],e=0,f=0,g,h;g=0;for(h=a.length;g<h;++g){var l=a.charCodeAt(g)-63,e=e|(l&31)<<f;32>l?(d.push(e),f=e=0):f+=5}e=0;for(f=d.length;e<f;++e)g=d[e],d[e]=g&1?~(g>>1):g>>1;e=0;for(f=d.length;e<f;++e)d[e]/=c;return d}k=Mq.prototype;k.$d=function(a,b){var c=this.yd(a,b);return new I(c)};k.tg=function(a,b){return[this.$d(a,b)]};k.yd=function(a,b){var c=pf(this.a),d=Pq(a,c,this.b);Lq(d,d.length,c,d);c=Cf(d,0,d.length,c);return Hl(new N(c,this.a),!1,Gl(this,b))};
k.fe=function(a,b){var c=a.U();if(c)return this.Ed(c,b);sa(!1,40);return""};k.Og=function(a,b){return this.fe(a[0],b)};k.Ed=function(a,b){a=Hl(a,!0,Gl(this,b));var c=a.ia(),d=a.sa();Lq(c,c.length,d,c);return Nq(c,d,this.b)};function Rq(a){a=a?a:{};El.call(this);this.defaultDataProjection=Tb(a.defaultDataProjection?a.defaultDataProjection:"EPSG:4326")}u(Rq,Il);function Sq(a,b){var c=[],d,e,f,g;f=0;for(g=a.length;f<g;++f)d=a[f],0<f&&c.pop(),0<=d?e=b[d]:e=b[~d].slice().reverse(),c.push.apply(c,e);d=0;for(e=c.length;d<e;++d)c[d]=c[d].slice();return c}function Tq(a,b,c,d,e){a=a.geometries;var f=[],g,h;g=0;for(h=a.length;g<h;++g)f[g]=Uq(a[g],b,c,d,e);return f}
function Uq(a,b,c,d,e){var f=a.type,g=Vq[f];b="Point"===f||"MultiPoint"===f?g(a,c,d):g(a,b);c=new I;c.Ta(Hl(b,!1,e));void 0!==a.id&&c.lc(a.id);a.properties&&c.H(a.properties);return c}
Rq.prototype.sg=function(a,b){if("Topology"==a.type){var c,d=null,e=null;a.transform&&(c=a.transform,d=c.scale,e=c.translate);var f=a.arcs;if(c){c=d;var g=e,h,l;h=0;for(l=f.length;h<l;++h){var m,n,p,q=f[h],r=c,v=g,x=0,y=0;n=0;for(m=q.length;n<m;++n)p=q[n],x+=p[0],y+=p[1],p[0]=x,p[1]=y,Wq(p,r,v)}}c=[];g=sb(a.objects);h=0;for(l=g.length;h<l;++h)"GeometryCollection"===g[h].type?(m=g[h],c.push.apply(c,Tq(m,f,d,e,b))):(m=g[h],c.push(Uq(m,f,d,e,b)));return c}return[]};
function Wq(a,b,c){a[0]=a[0]*b[0]+c[0];a[1]=a[1]*b[1]+c[1]}Rq.prototype.zg=function(){return this.defaultDataProjection};
var Vq={Point:function(a,b,c){a=a.coordinates;b&&c&&Wq(a,b,c);return new E(a)},LineString:function(a,b){var c=Sq(a.arcs,b);return new N(c)},Polygon:function(a,b){var c=[],d,e;d=0;for(e=a.arcs.length;d<e;++d)c[d]=Sq(a.arcs[d],b);return new F(c)},MultiPoint:function(a,b,c){a=a.coordinates;var d,e;if(b&&c)for(d=0,e=a.length;d<e;++d)Wq(a[d],b,c);return new P(a)},MultiLineString:function(a,b){var c=[],d,e;d=0;for(e=a.arcs.length;d<e;++d)c[d]=Sq(a.arcs[d],b);return new O(c)},MultiPolygon:function(a,b){var c=
[],d,e,f,g,h,l;h=0;for(l=a.arcs.length;h<l;++h){d=a.arcs[h];e=[];f=0;for(g=d.length;f<g;++f)e[f]=Sq(d[f],b);c[h]=e}return new Q(c)}};k=Rq.prototype;k.dd=function(){};k.ge=function(){};k.ie=function(){};k.wg=function(){};k.Wc=function(){};function Xq(a){a=a?a:{};this.c=a.featureType;this.a=a.featureNS;this.b=a.gmlFormat?a.gmlFormat:new Rm;this.l=a.schemaLocation?a.schemaLocation:Yq["1.1.0"];Bm.call(this)}u(Xq,Bm);var Yq={"1.1.0":"http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.1.0/wfs.xsd","1.0.0":"http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.0.0/wfs.xsd"};
Xq.prototype.Bc=function(a,b){var c={featureType:this.c,featureNS:this.a};qb(c,Fl(this,a,b?b:{}));c=[c];this.b.b["http://www.opengis.net/gml"].featureMember=sl(Em.prototype.ae);(c=M([],this.b.b,a,c,this.b))||(c=[]);return c};Xq.prototype.j=function(a){if(nl(a))return Zq(a);if(pl(a))return M({},$q,a,[]);if("string"===typeof a)return a=ql(a),Zq(a)};Xq.prototype.f=function(a){if(nl(a))return ar(this,a);if(pl(a))return br(this,a);if("string"===typeof a)return a=ql(a),ar(this,a)};
function ar(a,b){for(var c=b.firstChild;c;c=c.nextSibling)if(c.nodeType==Node.ELEMENT_NODE)return br(a,c)}var cr={"http://www.opengis.net/gml":{boundedBy:J(Em.prototype.ef,"bounds")}};function br(a,b){var c={},d=Mm(b.getAttribute("numberOfFeatures"));c.numberOfFeatures=d;return M(c,cr,b,[],a.b)}
var dr={"http://www.opengis.net/wfs":{totalInserted:J(Lm),totalUpdated:J(Lm),totalDeleted:J(Lm)}},er={"http://www.opengis.net/ogc":{FeatureId:sl(function(a){return a.getAttribute("fid")})}},fr={"http://www.opengis.net/wfs":{Feature:function(a,b){Al(er,a,b)}}},$q={"http://www.opengis.net/wfs":{TransactionSummary:J(function(a,b){return M({},dr,a,b)},"transactionSummary"),InsertResults:J(function(a,b){return M([],fr,a,b)},"insertIds")}};
function Zq(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType==Node.ELEMENT_NODE)return M({},$q,a,[])}var gr={"http://www.opengis.net/wfs":{PropertyName:K(Om)}};function hr(a,b){var c=kl("http://www.opengis.net/ogc","Filter"),d=kl("http://www.opengis.net/ogc","FeatureId");c.appendChild(d);d.setAttribute("fid",b);a.appendChild(c)}
var ir={"http://www.opengis.net/wfs":{Insert:K(function(a,b,c){var d=c[c.length-1],e=d.gmlVersion,d=kl(d.featureNS,d.featureType);a.appendChild(d);if(2===e){a=$m.prototype;(e=b.a)&&d.setAttribute("fid",e);var e=c[c.length-1],f=e.featureNS,g=b.c;e.kb||(e.kb={},e.kb[f]={});var h=b.M();b=[];var l=[],m;for(m in h){var n=h[m];null!==n&&(b.push(m),l.push(n),m==g||n instanceof lf?m in e.kb[f]||(e.kb[f][m]=K(a.Uh,a)):m in e.kb[f]||(e.kb[f][m]=K(Om)))}m=qb({},e);m.node=d;Bl(m,e.kb,wl(void 0,f),l,c,b)}else Rm.prototype.bi(d,
b,c)}),Update:K(function(a,b,c){var d=c[c.length-1];sa(void 0!==b.a,27);var e=d.featureType,f=d.featurePrefix,f=f?f:"feature",g=d.featureNS;a.setAttribute("typeName",f+":"+e);a.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:"+f,g);e=b.a;if(void 0!==e){for(var f=b.P(),g=[],h=0,l=f.length;h<l;h++){var m=b.get(f[h]);void 0!==m&&g.push({name:f[h],value:m})}Bl({gmlVersion:d.gmlVersion,node:a,srsName:d.srsName},ir,wl("Property"),g,c);hr(a,e)}}),Delete:K(function(a,b,c){var d=c[c.length-1];sa(void 0!==
b.a,26);c=d.featureType;var e=d.featurePrefix,e=e?e:"feature",d=d.featureNS;a.setAttribute("typeName",e+":"+c);a.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:"+e,d);b=b.a;void 0!==b&&hr(a,b)}),Property:K(function(a,b,c){var d=kl("http://www.opengis.net/wfs","Name"),e=c[c.length-1].gmlVersion;a.appendChild(d);Om(d,b.name);void 0!==b.value&&null!==b.value&&(d=kl("http://www.opengis.net/wfs","Value"),a.appendChild(d),b.value instanceof lf?2===e?$m.prototype.Uh(d,b.value,c):Rm.prototype.rd(d,
b.value,c):Om(d,b.value))}),Native:K(function(a,b){b.kq&&a.setAttribute("vendorId",b.kq);void 0!==b.Lp&&a.setAttribute("safeToIgnore",b.Lp);void 0!==b.value&&Om(a,b.value)})}};function jr(a,b,c){var d={node:a};b.b.forEach(function(a){Bl(d,kr,wl(a.mc),[a],c)})}function lr(a,b){void 0!==b.a&&a.setAttribute("matchCase",b.a.toString());mr(a,b.b);nr(a,""+b.g)}function or(a,b,c){a=kl("http://www.opengis.net/ogc",a);Om(a,c);b.appendChild(a)}function mr(a,b){or("PropertyName",a,b)}
function nr(a,b){or("Literal",a,b)}
var kr={"http://www.opengis.net/wfs":{Query:K(function(a,b,c){var d=c[c.length-1],e=d.featurePrefix,f=d.featureNS,g=d.propertyNames,h=d.srsName;a.setAttribute("typeName",(e?e+":":"")+b);h&&a.setAttribute("srsName",h);f&&a.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:"+e,f);b=qb({},d);b.node=a;Bl(b,gr,wl("PropertyName"),g,c);if(d=d.filter)g=kl("http://www.opengis.net/ogc","Filter"),a.appendChild(g),Bl({node:g},kr,wl(d.mc),[d],c)})},"http://www.opengis.net/ogc":{And:K(jr),Or:K(jr),Not:K(function(a,
b,c){b=b.condition;Bl({node:a},kr,wl(b.mc),[b],c)}),BBOX:K(function(a,b,c){c[c.length-1].srsName=b.srsName;mr(a,b.geometryName);Rm.prototype.rd(a,b.extent,c)}),Intersects:K(function(a,b,c){c[c.length-1].srsName=b.srsName;mr(a,b.geometryName);Rm.prototype.rd(a,b.geometry,c)}),Within:K(function(a,b,c){c[c.length-1].srsName=b.srsName;mr(a,b.geometryName);Rm.prototype.rd(a,b.geometry,c)}),PropertyIsEqualTo:K(lr),PropertyIsNotEqualTo:K(lr),PropertyIsLessThan:K(lr),PropertyIsLessThanOrEqualTo:K(lr),PropertyIsGreaterThan:K(lr),
PropertyIsGreaterThanOrEqualTo:K(lr),PropertyIsNull:K(function(a,b){mr(a,b.b)}),PropertyIsBetween:K(function(a,b){mr(a,b.b);var c=kl("http://www.opengis.net/ogc","LowerBoundary");a.appendChild(c);nr(c,""+b.a);c=kl("http://www.opengis.net/ogc","UpperBoundary");a.appendChild(c);nr(c,""+b.g)}),PropertyIsLike:K(function(a,b){a.setAttribute("wildCard",b.f);a.setAttribute("singleChar",b.i);a.setAttribute("escapeChar",b.g);void 0!==b.a&&a.setAttribute("matchCase",b.a.toString());mr(a,b.b);nr(a,""+b.c)})}};
Xq.prototype.o=function(a){var b=kl("http://www.opengis.net/wfs","GetFeature");b.setAttribute("service","WFS");b.setAttribute("version","1.1.0");var c;if(a&&(a.handle&&b.setAttribute("handle",a.handle),a.outputFormat&&b.setAttribute("outputFormat",a.outputFormat),void 0!==a.maxFeatures&&b.setAttribute("maxFeatures",a.maxFeatures),a.resultType&&b.setAttribute("resultType",a.resultType),void 0!==a.startIndex&&b.setAttribute("startIndex",a.startIndex),void 0!==a.count&&b.setAttribute("count",a.count),
c=a.filter,a.bbox)){sa(a.geometryName,12);var d=rm(a.geometryName,a.bbox,a.srsName);c?c=qm(c,d):c=d}b.setAttributeNS("http://www.w3.org/2001/XMLSchema-instance","xsi:schemaLocation",this.l);c={node:b,srsName:a.srsName,featureNS:a.featureNS?a.featureNS:this.a,featurePrefix:a.featurePrefix,geometryName:a.geometryName,filter:c,propertyNames:a.propertyNames?a.propertyNames:[]};sa(Array.isArray(a.featureTypes),11);a=a.featureTypes;c=[c];d=qb({},c[c.length-1]);d.node=b;Bl(d,kr,wl("Query"),a,c);return b};
Xq.prototype.u=function(a,b,c,d){var e=[],f=kl("http://www.opengis.net/wfs","Transaction"),g=d.version?d.version:"1.1.0",h="1.0.0"===g?2:3;f.setAttribute("service","WFS");f.setAttribute("version",g);var l;d&&(l=d.gmlOptions?d.gmlOptions:{},d.handle&&f.setAttribute("handle",d.handle));f.setAttributeNS("http://www.w3.org/2001/XMLSchema-instance","xsi:schemaLocation",Yq[g]);a&&(g={node:f,featureNS:d.featureNS,featureType:d.featureType,featurePrefix:d.featurePrefix,gmlVersion:h,srsName:d.srsName},qb(g,
l),Bl(g,ir,wl("Insert"),a,e));b&&(g={node:f,featureNS:d.featureNS,featureType:d.featureType,featurePrefix:d.featurePrefix,gmlVersion:h,srsName:d.srsName},qb(g,l),Bl(g,ir,wl("Update"),b,e));c&&Bl({node:f,featureNS:d.featureNS,featureType:d.featureType,featurePrefix:d.featurePrefix,gmlVersion:h,srsName:d.srsName},ir,wl("Delete"),c,e);d.nativeElements&&Bl({node:f,featureNS:d.featureNS,featureType:d.featureType,featurePrefix:d.featurePrefix,gmlVersion:h,srsName:d.srsName},ir,wl("Native"),d.nativeElements,
e);return f};Xq.prototype.yg=function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType==Node.ELEMENT_NODE)return this.hf(a);return null};Xq.prototype.hf=function(a){if(a.firstElementChild&&a.firstElementChild.firstElementChild)for(a=a.firstElementChild.firstElementChild,a=a.firstElementChild;a;a=a.nextElementSibling)if(0!==a.childNodes.length&&(1!==a.childNodes.length||3!==a.firstChild.nodeType)){var b=[{}];this.b.ef(a,b);return Tb(b.pop().srsName)}return null};function pr(a){a=a?a:{};El.call(this);this.b=void 0!==a.splitCollection?a.splitCollection:!1}u(pr,Un);function qr(a){a=a.W();return a.length?a.join(" "):""}function rr(a){a=a.W();for(var b=[],c=0,d=a.length;c<d;++c)b.push(a[c].join(" "));return b.join(",")}function sr(a){var b=[];a=a.Oc();for(var c=0,d=a.length;c<d;++c)b.push("("+rr(a[c])+")");return b.join(",")}
function tr(a){var b=a.S(),c=(0,ur[b])(a),b=b.toUpperCase();if(a instanceof of){a=a.la;var d="";if("XYZ"===a||"XYZM"===a)d+="Z";if("XYM"===a||"XYZM"===a)d+="M";a=d;0<a.length&&(b+=" "+a)}return c.length?b+"("+c+")":b+" EMPTY"}
var ur={Point:qr,LineString:rr,Polygon:sr,MultiPoint:function(a){var b=[];a=a.Zd();for(var c=0,d=a.length;c<d;++c)b.push("("+qr(a[c])+")");return b.join(",")},MultiLineString:function(a){var b=[];a=a.Nc();for(var c=0,d=a.length;c<d;++c)b.push("("+rr(a[c])+")");return b.join(",")},MultiPolygon:function(a){var b=[];a=a.md();for(var c=0,d=a.length;c<d;++c)b.push("("+sr(a[c])+")");return b.join(",")},GeometryCollection:function(a){var b=[];a=a.Qf();for(var c=0,d=a.length;c<d;++c)b.push(tr(a[c]));return b.join(",")}};
k=pr.prototype;k.$d=function(a,b){var c=this.yd(a,b);if(c){var d=new I;d.Ta(c);return d}return null};k.tg=function(a,b){var c=[],d=this.yd(a,b);this.b&&"GeometryCollection"==d.S()?c=d.a:c=[d];for(var e=[],f=0,g=c.length;f<g;++f)d=new I,d.Ta(c[f]),e.push(d);return e};k.yd=function(a,b){var c;c=new vr(new wr(a));xr(c);return(c=yr(c))?Hl(c,!1,b):null};k.fe=function(a,b){var c=a.U();return c?this.Ed(c,b):""};
k.Og=function(a,b){if(1==a.length)return this.fe(a[0],b);for(var c=[],d=0,e=a.length;d<e;++d)c.push(a[d].U());c=new sm(c);return this.Ed(c,b)};k.Ed=function(a,b){return tr(Hl(a,!0,b))};function wr(a){this.a=a;this.b=-1}
function zr(a){var b=a.a.charAt(++a.b),c={position:a.b,value:b};if("("==b)c.type=2;else if(","==b)c.type=5;else if(")"==b)c.type=3;else if("0"<=b&&"9">=b||"."==b||"-"==b){c.type=4;var d,b=a.b,e=!1,f=!1;do{if("."==d)e=!0;else if("e"==d||"E"==d)f=!0;d=a.a.charAt(++a.b)}while("0"<=d&&"9">=d||"."==d&&(void 0===e||!e)||!f&&("e"==d||"E"==d)||f&&("-"==d||"+"==d));a=parseFloat(a.a.substring(b,a.b--));c.value=a}else if("a"<=b&&"z">=b||"A"<=b&&"Z">=b){c.type=1;b=a.b;do d=a.a.charAt(++a.b);while("a"<=d&&"z">=
d||"A"<=d&&"Z">=d);a=a.a.substring(b,a.b--).toUpperCase();c.value=a}else{if(" "==b||"\t"==b||"\r"==b||"\n"==b)return zr(a);if(""===b)c.type=6;else throw Error("Unexpected character: "+b);}return c}function vr(a){this.g=a;this.a="XY"}function xr(a){a.b=zr(a.g)}function Ar(a,b){var c=a.b.type==b;c&&xr(a);return c}
function yr(a){var b=a.b;if(Ar(a,1)){var b=b.value,c="XY",d=a.b;1==a.b.type&&(d=d.value,"Z"===d?c="XYZ":"M"===d?c="XYM":"ZM"===d&&(c="XYZM"),"XY"!==c&&xr(a));a.a=c;if("GEOMETRYCOLLECTION"==b){a:{if(Ar(a,2)){b=[];do b.push(yr(a));while(Ar(a,5));if(Ar(a,3)){a=b;break a}}else if(Br(a)){a=[];break a}throw Error(Cr(a));}return new sm(a)}d=Dr[b];c=Er[b];if(!d||!c)throw Error("Invalid geometry type: "+b);b=d.call(a);return new c(b,a.a)}throw Error(Cr(a));}k=vr.prototype;
k.ng=function(){if(Ar(this,2)){var a=Fr(this);if(Ar(this,3))return a}else if(Br(this))return null;throw Error(Cr(this));};k.mg=function(){if(Ar(this,2)){var a=Gr(this);if(Ar(this,3))return a}else if(Br(this))return[];throw Error(Cr(this));};k.og=function(){if(Ar(this,2)){var a=Hr(this);if(Ar(this,3))return a}else if(Br(this))return[];throw Error(Cr(this));};
k.Vo=function(){if(Ar(this,2)){var a;if(2==this.b.type)for(a=[this.ng()];Ar(this,5);)a.push(this.ng());else a=Gr(this);if(Ar(this,3))return a}else if(Br(this))return[];throw Error(Cr(this));};k.Uo=function(){if(Ar(this,2)){var a=Hr(this);if(Ar(this,3))return a}else if(Br(this))return[];throw Error(Cr(this));};k.Wo=function(){if(Ar(this,2)){for(var a=[this.og()];Ar(this,5);)a.push(this.og());if(Ar(this,3))return a}else if(Br(this))return[];throw Error(Cr(this));};
function Fr(a){for(var b=[],c=a.a.length,d=0;d<c;++d){var e=a.b;if(Ar(a,4))b.push(e.value);else break}if(b.length==c)return b;throw Error(Cr(a));}function Gr(a){for(var b=[Fr(a)];Ar(a,5);)b.push(Fr(a));return b}function Hr(a){for(var b=[a.mg()];Ar(a,5);)b.push(a.mg());return b}function Br(a){var b=1==a.b.type&&"EMPTY"==a.b.value;b&&xr(a);return b}function Cr(a){return"Unexpected `"+a.b.value+"` at position "+a.b.position+" in `"+a.g.a+"`"}
var Er={POINT:E,LINESTRING:N,POLYGON:F,MULTIPOINT:P,MULTILINESTRING:O,MULTIPOLYGON:Q},Dr={POINT:vr.prototype.ng,LINESTRING:vr.prototype.mg,POLYGON:vr.prototype.og,MULTIPOINT:vr.prototype.Vo,MULTILINESTRING:vr.prototype.Uo,MULTIPOLYGON:vr.prototype.Wo};function Ir(){this.version=void 0}u(Ir,uq);Ir.prototype.a=function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType==Node.ELEMENT_NODE)return this.b(a);return null};Ir.prototype.b=function(a){this.version=a.getAttribute("version").trim();return(a=M({version:this.version},Jr,a,[]))?a:null};function Kr(a,b){return M({},Lr,a,b)}function Mr(a,b){return M({},Nr,a,b)}function Or(a,b){var c=Kr(a,b);if(c){var d=[Mm(a.getAttribute("width")),Mm(a.getAttribute("height"))];c.size=d;return c}}
function Pr(a,b){return M([],Qr,a,b)}
var Rr=[null,"http://www.opengis.net/wms"],Jr=L(Rr,{Service:J(function(a,b){return M({},Sr,a,b)}),Capability:J(function(a,b){return M({},Tr,a,b)})}),Tr=L(Rr,{Request:J(function(a,b){return M({},Ur,a,b)}),Exception:J(function(a,b){return M([],Vr,a,b)}),Layer:J(function(a,b){return M({},Wr,a,b)})}),Sr=L(Rr,{Name:J(R),Title:J(R),Abstract:J(R),KeywordList:J(Pr),OnlineResource:J(tq),ContactInformation:J(function(a,b){return M({},Xr,a,b)}),Fees:J(R),AccessConstraints:J(R),LayerLimit:J(Lm),MaxWidth:J(Lm),
MaxHeight:J(Lm)}),Xr=L(Rr,{ContactPersonPrimary:J(function(a,b){return M({},Yr,a,b)}),ContactPosition:J(R),ContactAddress:J(function(a,b){return M({},Zr,a,b)}),ContactVoiceTelephone:J(R),ContactFacsimileTelephone:J(R),ContactElectronicMailAddress:J(R)}),Yr=L(Rr,{ContactPerson:J(R),ContactOrganization:J(R)}),Zr=L(Rr,{AddressType:J(R),Address:J(R),City:J(R),StateOrProvince:J(R),PostCode:J(R),Country:J(R)}),Vr=L(Rr,{Format:sl(R)}),Wr=L(Rr,{Name:J(R),Title:J(R),Abstract:J(R),KeywordList:J(Pr),CRS:ul(R),
EX_GeographicBoundingBox:J(function(a,b){var c=M({},$r,a,b);if(c){var d=c.westBoundLongitude,e=c.southBoundLatitude,f=c.eastBoundLongitude,c=c.northBoundLatitude;if(void 0!==d&&void 0!==e&&void 0!==f&&void 0!==c)return[d,e,f,c]}}),BoundingBox:ul(function(a){var b=[Km(a.getAttribute("minx")),Km(a.getAttribute("miny")),Km(a.getAttribute("maxx")),Km(a.getAttribute("maxy"))],c=[Km(a.getAttribute("resx")),Km(a.getAttribute("resy"))];return{crs:a.getAttribute("CRS"),extent:b,res:c}}),Dimension:ul(function(a){return{name:a.getAttribute("name"),
units:a.getAttribute("units"),unitSymbol:a.getAttribute("unitSymbol"),"default":a.getAttribute("default"),multipleValues:Hm(a.getAttribute("multipleValues")),nearestValue:Hm(a.getAttribute("nearestValue")),current:Hm(a.getAttribute("current")),values:R(a)}}),Attribution:J(function(a,b){return M({},as,a,b)}),AuthorityURL:ul(function(a,b){var c=Kr(a,b);if(c)return c.name=a.getAttribute("name"),c}),Identifier:ul(R),MetadataURL:ul(function(a,b){var c=Kr(a,b);if(c)return c.type=a.getAttribute("type"),
c}),DataURL:ul(Kr),FeatureListURL:ul(Kr),Style:ul(function(a,b){return M({},bs,a,b)}),MinScaleDenominator:J(Jm),MaxScaleDenominator:J(Jm),Layer:ul(function(a,b){var c=b[b.length-1],d=M({},Wr,a,b);if(d){var e=Hm(a.getAttribute("queryable"));void 0===e&&(e=c.queryable);d.queryable=void 0!==e?e:!1;e=Mm(a.getAttribute("cascaded"));void 0===e&&(e=c.cascaded);d.cascaded=e;e=Hm(a.getAttribute("opaque"));void 0===e&&(e=c.opaque);d.opaque=void 0!==e?e:!1;e=Hm(a.getAttribute("noSubsets"));void 0===e&&(e=c.noSubsets);
d.noSubsets=void 0!==e?e:!1;(e=Km(a.getAttribute("fixedWidth")))||(e=c.fixedWidth);d.fixedWidth=e;(e=Km(a.getAttribute("fixedHeight")))||(e=c.fixedHeight);d.fixedHeight=e;["Style","CRS","AuthorityURL"].forEach(function(a){a in c&&(d[a]=(d[a]||[]).concat(c[a]))});"EX_GeographicBoundingBox BoundingBox Dimension Attribution MinScaleDenominator MaxScaleDenominator".split(" ").forEach(function(a){a in d||(d[a]=c[a])});return d}})}),as=L(Rr,{Title:J(R),OnlineResource:J(tq),LogoURL:J(Or)}),$r=L(Rr,{westBoundLongitude:J(Jm),
eastBoundLongitude:J(Jm),southBoundLatitude:J(Jm),northBoundLatitude:J(Jm)}),Ur=L(Rr,{GetCapabilities:J(Mr),GetMap:J(Mr),GetFeatureInfo:J(Mr)}),Nr=L(Rr,{Format:ul(R),DCPType:ul(function(a,b){return M({},cs,a,b)})}),cs=L(Rr,{HTTP:J(function(a,b){return M({},ds,a,b)})}),ds=L(Rr,{Get:J(Kr),Post:J(Kr)}),bs=L(Rr,{Name:J(R),Title:J(R),Abstract:J(R),LegendURL:ul(Or),StyleSheetURL:J(Kr),StyleURL:J(Kr)}),Lr=L(Rr,{Format:J(R),OnlineResource:J(tq)}),Qr=L(Rr,{Keyword:sl(R)});function es(a){a=a?a:{};this.a="http://mapserver.gis.umn.edu/mapserver";this.b=new $m;this.c=a.layers?a.layers:null;Bm.call(this)}u(es,Bm);
es.prototype.Bc=function(a,b){var c={};b&&qb(c,Fl(this,a,b));var d=[c];a.setAttribute("namespaceURI",this.a);var e=a.localName,c=[];if(a.childNodes.length){if("msGMLOutput"==e)for(var f=0,g=a.childNodes.length;f<g;f++){var h=a.childNodes[f];if(h.nodeType===Node.ELEMENT_NODE){var l=d[0],m=h.localName.replace("_layer","");if(!this.c||fa(this.c,m)){m+="_feature";l.featureType=m;l.featureNS=this.a;var n={};n[m]=sl(this.b.qg,this.b);l=L([l.featureNS,null],n);h.setAttribute("namespaceURI",this.a);(h=M([],
l,h,d,this.b))&&ha(c,h)}}}"FeatureCollection"==e&&(d=M([],this.b.b,a,[{}],this.b))&&(c=d)}return c};es.prototype.Ng=function(){};es.prototype.Zb=function(){};es.prototype.he=function(){};function fs(){this.g=new vq}u(fs,uq);fs.prototype.a=function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType==Node.ELEMENT_NODE)return this.b(a);return null};fs.prototype.b=function(a){var b=a.getAttribute("version").trim(),c=this.g.b(a);if(!c)return null;c.version=b;return(c=M(c,gs,a,[]))?c:null};function hs(a){var b=R(a).split(" ");if(b&&2==b.length&&(a=+b[0],b=+b[1],!isNaN(a)&&!isNaN(b)))return[a,b]}
var is=[null,"http://www.opengis.net/wmts/1.0"],js=[null,"http://www.opengis.net/ows/1.1"],gs=L(is,{Contents:J(function(a,b){return M({},ks,a,b)})}),ks=L(is,{Layer:ul(function(a,b){return M({},ls,a,b)}),TileMatrixSet:ul(function(a,b){return M({},ms,a,b)})}),ls=L(is,{Style:ul(function(a,b){var c=M({},ns,a,b);if(c){var d="true"===a.getAttribute("isDefault");c.isDefault=d;return c}}),Format:ul(R),TileMatrixSetLink:ul(function(a,b){return M({},os,a,b)}),Dimension:ul(function(a,b){return M({},ps,a,b)}),
ResourceURL:ul(function(a){var b=a.getAttribute("format"),c=a.getAttribute("template");a=a.getAttribute("resourceType");var d={};b&&(d.format=b);c&&(d.template=c);a&&(d.resourceType=a);return d})},L(js,{Title:J(R),Abstract:J(R),WGS84BoundingBox:J(function(a,b){var c=M([],qs,a,b);if(2==c.length)return Ia(c)}),Identifier:J(R)})),ns=L(is,{LegendURL:ul(function(a){var b={};b.format=a.getAttribute("format");b.href=tq(a);return b})},L(js,{Title:J(R),Identifier:J(R)})),os=L(is,{TileMatrixSet:J(R),TileMatrixSetLimits:J(function(a,
b){return M([],rs,a,b)})}),rs=L(is,{TileMatrixLimits:sl(function(a,b){return M({},ss,a,b)})}),ss=L(is,{TileMatrix:J(R),MinTileRow:J(Lm),MaxTileRow:J(Lm),MinTileCol:J(Lm),MaxTileCol:J(Lm)}),ps=L(is,{Default:J(R),Value:ul(R)},L(js,{Identifier:J(R)})),qs=L(js,{LowerCorner:sl(hs),UpperCorner:sl(hs)}),ms=L(is,{WellKnownScaleSet:J(R),TileMatrix:ul(function(a,b){return M({},ts,a,b)})},L(js,{SupportedCRS:J(R),Identifier:J(R)})),ts=L(is,{TopLeftCorner:J(hs),ScaleDenominator:J(Jm),TileWidth:J(Lm),TileHeight:J(Lm),
MatrixWidth:J(Lm),MatrixHeight:J(Lm)},L(js,{Identifier:J(R)}));function us(a){Qc.call(this);a=a||{};this.a=null;this.i=ec;this.c=void 0;z(this,Sc("projection"),this.wm,this);z(this,Sc("tracking"),this.xm,this);void 0!==a.projection&&this.Ph(Tb(a.projection));void 0!==a.trackingOptions&&this.sj(a.trackingOptions);this.Je(void 0!==a.tracking?a.tracking:!1)}u(us,Qc);k=us.prototype;k.ra=function(){this.Je(!1);Qc.prototype.ra.call(this)};k.wm=function(){var a=this.Nh();a&&(this.i=Sb(Tb("EPSG:4326"),a),this.a&&this.set("position",this.i(this.a)))};
k.xm=function(){if(Xd){var a=this.Oh();a&&void 0===this.c?this.c=navigator.geolocation.watchPosition(this.cp.bind(this),this.ep.bind(this),this.zh()):a||void 0===this.c||(navigator.geolocation.clearWatch(this.c),this.c=void 0)}};
k.cp=function(a){a=a.coords;this.set("accuracy",a.accuracy);this.set("altitude",null===a.altitude?void 0:a.altitude);this.set("altitudeAccuracy",null===a.altitudeAccuracy?void 0:a.altitudeAccuracy);this.set("heading",null===a.heading?void 0:Ca(a.heading));this.a?(this.a[0]=a.longitude,this.a[1]=a.latitude):this.a=[a.longitude,a.latitude];var b=this.i(this.a);this.set("position",b);this.set("speed",null===a.speed?void 0:a.speed);a=Uf(Hb,this.a,a.accuracy);a.Fc(this.i);this.set("accuracyGeometry",a);
this.s()};k.ep=function(a){a.type="error";this.Je(!1);this.b(a)};k.zk=function(){return this.get("accuracy")};k.Ak=function(){return this.get("accuracyGeometry")||null};k.Ck=function(){return this.get("altitude")};k.Dk=function(){return this.get("altitudeAccuracy")};k.um=function(){return this.get("heading")};k.vm=function(){return this.get("position")};k.Nh=function(){return this.get("projection")};k.gl=function(){return this.get("speed")};k.Oh=function(){return this.get("tracking")};k.zh=function(){return this.get("trackingOptions")};
k.Ph=function(a){this.set("projection",a)};k.Je=function(a){this.set("tracking",a)};k.sj=function(a){this.set("trackingOptions",a)};function vs(a,b,c){of.call(this);this.Gg(a,b?b:0,c)}u(vs,of);k=vs.prototype;k.clone=function(){var a=new vs(null);qf(a,this.la,this.B.slice());a.s();return a};k.Hb=function(a,b,c,d){var e=this.B;a-=e[0];var f=b-e[1];b=a*a+f*f;if(b<d){if(b)for(d=this.Yd()/Math.sqrt(b),c[0]=e[0]+d*a,c[1]=e[1]+d*f,d=2;d<this.a;++d)c[d]=e[d];else for(d=0;d<this.a;++d)c[d]=e[d];c.length=this.a;return b}return d};k.Sc=function(a,b){var c=this.B,d=a-c[0],c=b-c[1];return d*d+c*c<=ws(this)};
k.za=function(){return this.B.slice(0,this.a)};k.se=function(a){var b=this.B,c=b[this.a]-b[0];return Wa(b[0]-c,b[1]-c,b[0]+c,b[1]+c,a)};k.Yd=function(){return Math.sqrt(ws(this))};function ws(a){var b=a.B[a.a]-a.B[0];a=a.B[a.a+1]-a.B[1];return b*b+a*a}k.S=function(){return"Circle"};k.Ya=function(a){var b=this.D();return nb(a,b)?(b=this.za(),a[0]<=b[0]&&a[2]>=b[0]||a[1]<=b[1]&&a[3]>=b[1]?!0:bb(a,this.sb,this)):!1};
k.lb=function(a){var b=this.a,c=a.slice();c[b]=c[0]+(this.B[b]-this.B[0]);var d;for(d=1;d<b;++d)c[b+d]=a[d];qf(this,this.la,c);this.s()};k.Gg=function(a,b,c){if(a){rf(this,c,a,0);this.B||(this.B=[]);c=this.B;a=zf(c,a);c[a++]=c[0]+b;var d;b=1;for(d=this.a;b<d;++b)c[a++]=c[b];c.length=a}else qf(this,"XY",null);this.s()};k.W=function(){};k.pa=function(){};k.Zc=function(a){this.B[this.a]=this.B[0]+a;this.s()};function xs(a,b,c){for(var d=[],e=a(0),f=a(1),g=b(e),h=b(f),l=[f,e],m=[h,g],n=[1,0],p={},q=1E5,r,v,x,y,A;0<--q&&0<n.length;)x=n.pop(),e=l.pop(),g=m.pop(),f=x.toString(),f in p||(d.push(g[0],g[1]),p[f]=!0),y=n.pop(),f=l.pop(),h=m.pop(),A=(x+y)/2,r=a(A),v=b(r),Aa(v[0],v[1],g[0],g[1],h[0],h[1])<c?(d.push(h[0],h[1]),f=y.toString(),p[f]=!0):(n.push(y,A,A,x),m.push(h,v,v,g),l.push(f,r,r,e));return d}function ys(a,b,c,d,e){var f=Tb("EPSG:4326");return xs(function(d){return[a,b+(c-b)*d]},dc(f,d),e)}
function zs(a,b,c,d,e){var f=Tb("EPSG:4326");return xs(function(d){return[b+(c-b)*d,a]},dc(f,d),e)};function As(a){a=a||{};this.i=this.l=null;this.g=this.f=Infinity;this.c=this.j=-Infinity;this.A=this.O=Infinity;this.G=this.C=-Infinity;this.I=void 0!==a.targetSize?a.targetSize:100;this.qa=void 0!==a.maxLines?a.maxLines:100;this.b=[];this.a=[];this.ta=void 0!==a.strokeStyle?a.strokeStyle:Bs;this.v=this.o=void 0;this.u=null;this.setMap(void 0!==a.map?a.map:null)}var Bs=new tj({color:"rgba(0,0,0,0.2)"}),Cs=[90,45,30,20,10,5,2,1,.5,.2,.1,.05,.01,.005,.002,.001];
function Ds(a,b,c,d,e,f,g){var h=g;b=ys(b,c,d,a.i,e);h=void 0!==a.b[h]?a.b[h]:new N(null);h.ca("XY",b);nb(h.D(),f)&&(a.b[g++]=h);return g}function Es(a,b,c,d,e){var f=e;b=zs(b,a.c,a.g,a.i,c);f=void 0!==a.a[f]?a.a[f]:new N(null);f.ca("XY",b);nb(f.D(),d)&&(a.a[e++]=f);return e}k=As.prototype;k.ym=function(){return this.l};k.Wk=function(){return this.b};k.cl=function(){return this.a};
k.Dh=function(a){var b=a.vectorContext,c=a.frameState,d=c.extent;a=c.viewState;var e=a.center,f=a.projection,g=a.resolution;a=c.pixelRatio;a=g*g/(4*a*a);if(!this.i||!bc(this.i,f)){var h=Tb("EPSG:4326"),l=f.D(),m=f.f,n=gc(m,h,f),p=m[2],q=m[1],r=m[0],v=n[3],x=n[2],y=n[1],n=n[0];this.f=m[3];this.g=p;this.j=q;this.c=r;this.O=v;this.A=x;this.C=y;this.G=n;this.o=dc(h,f);this.v=dc(f,h);this.u=this.v(kb(l));this.i=f}f.a&&(f=f.D(),h=ib(f),c=c.focus[0],c<f[0]||c>f[2])&&(c=h*Math.ceil((f[0]-c)/h),d=[d[0]+c,
d[1],d[2]+c,d[3]]);c=this.u[0];f=this.u[1];h=-1;m=Math.pow(this.I*g,2);p=[];q=[];g=0;for(l=Cs.length;g<l;++g){r=Cs[g]/2;p[0]=c-r;p[1]=f-r;q[0]=c+r;q[1]=f+r;this.o(p,p);this.o(q,q);r=Math.pow(q[0]-p[0],2)+Math.pow(q[1]-p[1],2);if(r<=m)break;h=Cs[g]}g=h;if(-1==g)this.b.length=this.a.length=0;else{c=this.v(e);e=c[0];c=c[1];f=this.qa;h=[Math.max(d[0],this.G),Math.max(d[1],this.C),Math.min(d[2],this.A),Math.min(d[3],this.O)];h=gc(h,this.i,"EPSG:4326");m=h[3];q=h[1];e=Math.floor(e/g)*g;p=xa(e,this.c,this.g);
l=Ds(this,p,q,m,a,d,0);for(h=0;p!=this.c&&h++<f;)p=Math.max(p-g,this.c),l=Ds(this,p,q,m,a,d,l);p=xa(e,this.c,this.g);for(h=0;p!=this.g&&h++<f;)p=Math.min(p+g,this.g),l=Ds(this,p,q,m,a,d,l);this.b.length=l;c=Math.floor(c/g)*g;e=xa(c,this.j,this.f);l=Es(this,e,a,d,0);for(h=0;e!=this.j&&h++<f;)e=Math.max(e-g,this.j),l=Es(this,e,a,d,l);e=xa(c,this.j,this.f);for(h=0;e!=this.f&&h++<f;)e=Math.min(e+g,this.f),l=Es(this,e,a,d,l);this.a.length=l}b.Na(null,this.ta);a=0;for(e=this.b.length;a<e;++a)g=this.b[a],
b.Rb(g,null);a=0;for(e=this.a.length;a<e;++a)g=this.a[a],b.Rb(g,null)};k.setMap=function(a){this.l&&(this.l.K("postcompose",this.Dh,this),this.l.render());a&&(a.J("postcompose",this.Dh,this),a.render());this.l=a};function Fs(a,b,c,d,e){Nc.call(this);this.i=e;this.extent=a;this.a=c;this.resolution=b;this.state=d}u(Fs,Nc);Fs.prototype.s=function(){this.b("change")};Fs.prototype.D=function(){return this.extent};Fs.prototype.V=function(){return this.state};function Gs(a,b,c,d,e,f,g){Fs.call(this,a,b,c,0,d);this.j=e;this.N=new Image;null!==f&&(this.N.crossOrigin=f);this.c={};this.g=null;this.state=0;this.f=g}u(Gs,Fs);k=Gs.prototype;k.Y=function(a){if(void 0!==a){var b;a=w(a);if(a in this.c)return this.c[a];tb(this.c)?b=this.N:b=this.N.cloneNode(!1);return this.c[a]=b}return this.N};k.Bm=function(){this.state=3;this.g.forEach(Bc);this.g=null;this.s()};
k.Cm=function(){void 0===this.resolution&&(this.resolution=jb(this.extent)/this.N.height);this.state=2;this.g.forEach(Bc);this.g=null;this.s()};k.load=function(){if(0==this.state||3==this.state)this.state=1,this.s(),this.g=[Gc(this.N,"error",this.Bm,this),Gc(this.N,"load",this.Cm,this)],this.f(this,this.j)};k.Hg=function(a){this.N=a};function Hs(a,b,c,d,e,f){this.c=f?f:null;Fs.call(this,a,b,c,f?0:2,d);this.g=e}u(Hs,Fs);Hs.prototype.f=function(a){this.state=a?3:2;this.s()};Hs.prototype.load=function(){0==this.state&&(this.state=1,this.s(),this.c(this.f.bind(this)))};Hs.prototype.Y=function(){return this.g};function Is(a,b){Nc.call(this);this.Ga=a;this.state=b;this.a=null;this.key=""}u(Is,Nc);Is.prototype.s=function(){this.b("change")};Is.prototype.hb=function(){return this.key+"/"+this.Ga};function Js(a){if(!a.a)return a;var b=a.a;do{if(2==b.V())return b;b=b.a}while(b);return a}Is.prototype.i=function(){return this.Ga};Is.prototype.V=function(){return this.state};function Ks(a,b,c,d,e){Is.call(this,a,b);this.f=c;this.N=new Image;null!==d&&(this.N.crossOrigin=d);this.c=null;this.l=e}u(Ks,Is);k=Ks.prototype;k.ra=function(){1==this.state&&Ls(this);this.a&&Kc(this.a);this.state=5;this.s();Is.prototype.ra.call(this)};k.Y=function(){return this.N};k.hb=function(){return this.f};k.zm=function(){this.state=3;Ls(this);this.s()};k.Am=function(){this.state=this.N.naturalWidth&&this.N.naturalHeight?2:4;Ls(this);this.s()};
k.load=function(){if(0==this.state||3==this.state)this.state=1,this.s(),this.c=[Gc(this.N,"error",this.zm,this),Gc(this.N,"load",this.Am,this)],this.l(this,this.f)};function Ls(a){a.c.forEach(Bc);a.c=null};function Ms(a){a=a?a:{};kg.call(this,{handleEvent:jf});this.f=a.formatConstructors?a.formatConstructors:[];this.l=a.projection?Tb(a.projection):null;this.a=null;this.target=a.target?a.target:null}u(Ms,kg);function Ns(a){a=a.dataTransfer.files;var b,c,d;b=0;for(c=a.length;b<c;++b){d=a.item(b);var e=new FileReader;e.addEventListener("load",this.j.bind(this,d));e.readAsText(d)}}function Os(a){a.stopPropagation();a.preventDefault();a.dataTransfer.dropEffect="copy"}
Ms.prototype.j=function(a,b){var c=b.target.result,d=this.v,e=this.l;e||(e=d.$().o);var d=this.f,f=[],g,h;g=0;for(h=d.length;g<h;++g){var l=new d[g];var m={featureProjection:e};try{f=l.Pa(c,m)}catch(n){f=null}if(f&&0<f.length)break}this.b(new Ps(Qs,a,f,e))};Ms.prototype.setMap=function(a){this.a&&(this.a.forEach(Bc),this.a=null);kg.prototype.setMap.call(this,a);a&&(a=this.target?this.target:a.c,this.a=[z(a,"drop",Ns,this),z(a,"dragenter",Os,this),z(a,"dragover",Os,this),z(a,"drop",Os,this)])};
var Qs="addfeatures";function Ps(a,b,c,d){Lc.call(this,a);this.features=c;this.file=b;this.projection=d}u(Ps,Lc);function Rs(a){a=a?a:{};Ag.call(this,{handleDownEvent:Ss,handleDragEvent:Ts,handleUpEvent:Us});this.o=a.condition?a.condition:wg;this.a=this.f=void 0;this.j=0;this.u=void 0!==a.duration?a.duration:400}u(Rs,Ag);function Ts(a){if(yg(a)){var b=a.map,c=b.Nb(),d=a.pixel;a=d[0]-c[0]/2;d=c[1]/2-d[1];c=Math.atan2(d,a);a=Math.sqrt(a*a+d*d);b=b.$();void 0!==this.f&&(d=c-this.f,lg(b,b.Sa()-d));this.f=c;void 0!==this.a&&(c=this.a*(b.Ra()/a),ng(b,c));void 0!==this.a&&(this.j=this.a/a);this.a=a}}
function Us(a){if(!yg(a))return!0;a=a.map.$();$f(a,1,-1);var b=this.j-1,c=a.Sa(),c=a.constrainRotation(c,0);lg(a,c,void 0,void 0);var c=a.Ra(),d=this.u,c=a.constrainResolution(c,0,b);ng(a,c,void 0,d);this.j=0;return!1}function Ss(a){return yg(a)&&this.o(a)?($f(a.map.$(),1,1),this.a=this.f=void 0,!0):!1};function Vs(a,b,c,d){this.na=a;this.T=b;this.overlaps=d;this.c=0;this.resolution=c;this.I=this.ta=null;this.a=[];this.coordinates=[];this.ea=yh();this.b=[];this.qa=null;this.mb=yh();this.fa=yh()}u(Vs,Th);
function Ws(a,b,c,d,e,f,g){var h=a.coordinates.length,l=a.Nf();g&&(c+=e);g=[b[c],b[c+1]];var m=[NaN,NaN],n=!0,p,q,r;for(p=c+e;p<d;p+=e)m[0]=b[p],m[1]=b[p+1],r=Va(l,m),r!==q?(n&&(a.coordinates[h++]=g[0],a.coordinates[h++]=g[1]),a.coordinates[h++]=m[0],a.coordinates[h++]=m[1],n=!1):1===r?(a.coordinates[h++]=m[0],a.coordinates[h++]=m[1],n=!1):n=!0,g[0]=m[0],g[1]=m[1],q=r;if(f&&n||p===c+e)a.coordinates[h++]=g[0],a.coordinates[h++]=g[1];return h}
function Xs(a,b){a.ta=[0,b,0];a.a.push(a.ta);a.I=[0,b,0];a.b.push(a.I)}Vs.prototype.Wa=function(a,b){if(this.$a){var c=Dh(this.ea,this.$a.slice());a.translate(c[0],c[1]);a.rotate(b)}a.fill();this.$a&&a.setTransform.apply(a,this.fa)};
function Ys(a,b,c,d,e,f,g,h,l){var m;a.qa&&ja(d,a.ea)?m=a.qa:(a.qa||(a.qa=[]),m=mf(a.coordinates,0,a.coordinates.length,2,d,a.qa),Ch(a.ea,d));d=!tb(f);for(var n=0,p=g.length,q=0,r,v=a.mb,x=a.fa,y,A,B,aa,Ra=0,ra=0,Ka=a.a!=g||a.overlaps?0:200;n<p;){var C=g[n],Na,wb,Z,Ta;switch(C[0]){case 0:q=C[1];d&&f[w(q).toString()]||!q.U()?n=C[2]:void 0===l||nb(l,q.U().D())?++n:n=C[2]+1;break;case 1:Ra>Ka&&(a.Wa(b,e),Ra=0);ra>Ka&&(b.stroke(),ra=0);Ra||ra||(b.beginPath(),y=A=NaN);++n;break;case 2:q=C[1];r=m[q];C=
m[q+1];B=m[q+2]-r;q=m[q+3]-C;q=Math.sqrt(B*B+q*q);b.moveTo(r+q,C);b.arc(r,C,q,0,2*Math.PI,!0);++n;break;case 3:b.closePath();++n;break;case 4:q=C[1];r=C[2];Na=C[3];wb=C[4]*c;Z=C[5]*c;var Pb=C[6],cc=C[7],$c=C[8],re=C[9];Ta=C[10];B=C[11];aa=C[12];var Jd=C[13],ug=C[14];for(Ta&&(B+=e);q<r;q+=2){C=m[q]-wb;Ta=m[q+1]-Z;Jd&&(C=Math.round(C),Ta=Math.round(Ta));if(1!=aa||B){var bf=C+wb,mh=Ta+Z;Hh(v,bf,mh,aa,aa,B,-bf,-mh);b.setTransform.apply(b,v)}bf=b.globalAlpha;1!=cc&&(b.globalAlpha=bf*cc);var mh=ug+$c>Na.width?
Na.width-$c:ug,sq=Pb+re>Na.height?Na.height-re:Pb;b.drawImage(Na,$c,re,mh,sq,C,Ta,mh*c,sq*c);1!=cc&&(b.globalAlpha=bf);(1!=aa||B)&&b.setTransform.apply(b,x)}++n;break;case 5:q=C[1];r=C[2];Z=C[3];Pb=C[4]*c;cc=C[5]*c;B=C[6];aa=C[7]*c;Na=C[8];wb=C[9];for((Ta=C[10])&&(B+=e);q<r;q+=2){C=m[q]+Pb;Ta=m[q+1]+cc;if(1!=aa||B)Hh(v,C,Ta,aa,aa,B,-C,-Ta),b.setTransform.apply(b,v);$c=Z.split("\n");re=$c.length;1<re?(Jd=Math.round(1.5*b.measureText("M").width),Ta-=(re-1)/2*Jd):Jd=0;for(ug=0;ug<re;ug++)bf=$c[ug],wb&&
b.strokeText(bf,C,Ta),Na&&b.fillText(bf,C,Ta),Ta+=Jd;(1!=aa||B)&&b.setTransform.apply(b,x)}++n;break;case 6:if(h&&(q=C[1],q=h(q)))return q;++n;break;case 7:Ka?Ra++:a.Wa(b,e);++n;break;case 8:q=C[1];r=C[2];C=m[q];Ta=m[q+1];B=C+.5|0;aa=Ta+.5|0;if(B!==y||aa!==A)b.moveTo(C,Ta),y=B,A=aa;for(q+=2;q<r;q+=2)if(C=m[q],Ta=m[q+1],B=C+.5|0,aa=Ta+.5|0,q==r-2||B!==y||aa!==A)b.lineTo(C,Ta),y=B,A=aa;++n;break;case 9:a.$a=C[2];Ra&&(a.Wa(b,e),Ra=0,ra&&(b.stroke(),ra=0));b.fillStyle=C[1];++n;break;case 10:var q=void 0!==
C[8]?C[8]:!0,jl=C[9];r=C[2];ra&&(b.stroke(),ra=0);b.strokeStyle=C[1];b.lineWidth=q?r*c:r;b.lineCap=C[3];b.lineJoin=C[4];b.miterLimit=C[5];Ud&&(r=C[6],B=C[7],q&&c!==jl&&(r=r.map(function(a){return a*c/jl}),B*=c/jl,C[6]=r,C[7]=B,C[9]=c),b.lineDashOffset=B,b.setLineDash(r));++n;break;case 11:b.font=C[1];b.textAlign=C[2];b.textBaseline=C[3];++n;break;case 12:Ka?ra++:b.stroke();++n;break;default:++n}}Ra&&a.Wa(b,e);ra&&b.stroke()}Vs.prototype.i=function(a,b,c,d,e){Ys(this,a,b,c,d,e,this.a,void 0,void 0)};
function Zs(a){var b=a.b;b.reverse();var c,d=b.length,e,f,g=-1;for(c=0;c<d;++c)if(e=b[c],f=e[0],6==f)g=c;else if(0==f){e[2]=c;e=a.b;for(f=c;g<f;){var h=e[g];e[g]=e[f];e[f]=h;++g;--f}g=-1}}function $s(a,b){a.ta[2]=a.a.length;a.ta=null;a.I[2]=a.b.length;a.I=null;var c=[6,b];a.a.push(c);a.b.push(c)}Vs.prototype.Se=oa;Vs.prototype.Nf=function(){return this.T};function at(a,b,c,d){Vs.call(this,a,b,c,d);this.N=this.Z=null;this.G=this.C=this.A=this.O=this.v=this.u=this.o=this.l=this.j=this.f=this.g=void 0}u(at,Vs);
at.prototype.sc=function(a,b){if(this.N){Xs(this,b);var c=a.ia(),d=this.coordinates.length,c=Ws(this,c,0,c.length,a.sa(),!1,!1);this.a.push([4,d,c,this.N,this.g,this.f,this.j,this.l,this.o,this.u,this.v,this.O,this.A,this.C,this.G]);this.b.push([4,d,c,this.Z,this.g,this.f,this.j,this.l,this.o,this.u,this.v,this.O,this.A,this.C,this.G]);$s(this,b)}};
at.prototype.qc=function(a,b){if(this.N){Xs(this,b);var c=a.ia(),d=this.coordinates.length,c=Ws(this,c,0,c.length,a.sa(),!1,!1);this.a.push([4,d,c,this.N,this.g,this.f,this.j,this.l,this.o,this.u,this.v,this.O,this.A,this.C,this.G]);this.b.push([4,d,c,this.Z,this.g,this.f,this.j,this.l,this.o,this.u,this.v,this.O,this.A,this.C,this.G]);$s(this,b)}};at.prototype.Se=function(){Zs(this);this.f=this.g=void 0;this.N=this.Z=null;this.G=this.C=this.O=this.v=this.u=this.o=this.l=this.A=this.j=void 0};
at.prototype.Wb=function(a){var b=a.Jc(),c=a.kc(),d=a.kg(1),e=a.Y(1),f=a.Tc();this.g=b[0];this.f=b[1];this.Z=d;this.N=e;this.j=c[1];this.l=a.f;this.o=f[0];this.u=f[1];this.v=a.o;this.O=a.j;this.A=a.c;this.C=a.u;this.G=c[0]};function bt(a,b,c,d){Vs.call(this,a,b,c,d);this.f=null;this.g={Nd:void 0,Hd:void 0,Id:null,Jd:void 0,Kd:void 0,Ld:void 0,Md:void 0,$f:0,strokeStyle:void 0,lineCap:void 0,lineDash:null,lineDashOffset:void 0,lineJoin:void 0,lineWidth:void 0,miterLimit:void 0}}u(bt,Vs);function ct(a,b,c,d,e){var f=a.coordinates.length;b=Ws(a,b,c,d,e,!1,!1);f=[8,f,b];a.a.push(f);a.b.push(f);return d}k=bt.prototype;k.Nf=function(){this.f||(this.f=Oa(this.T),0<this.c&&Ma(this.f,this.resolution*(this.c+1)/2,this.f));return this.f};
function dt(a){var b=a.g,c=b.strokeStyle,d=b.lineCap,e=b.lineDash,f=b.lineDashOffset,g=b.lineJoin,h=b.lineWidth,l=b.miterLimit;b.Nd==c&&b.Hd==d&&ja(b.Id,e)&&b.Jd==f&&b.Kd==g&&b.Ld==h&&b.Md==l||(b.$f!=a.coordinates.length&&(a.a.push([12]),b.$f=a.coordinates.length),a.a.push([10,c,h,d,g,l,e,f,!0,1],[1]),b.Nd=c,b.Hd=d,b.Id=e,b.Jd=f,b.Kd=g,b.Ld=h,b.Md=l)}
k.Rb=function(a,b){var c=this.g,d=c.lineWidth;void 0!==c.strokeStyle&&void 0!==d&&(dt(this),Xs(this,b),this.b.push([10,c.strokeStyle,c.lineWidth,c.lineCap,c.lineJoin,c.miterLimit,c.lineDash,c.lineDashOffset,!0,1],[1]),c=a.ia(),ct(this,c,0,c.length,a.sa()),this.b.push([12]),$s(this,b))};
k.pc=function(a,b){var c=this.g,d=c.lineWidth;if(void 0!==c.strokeStyle&&void 0!==d){dt(this);Xs(this,b);this.b.push([10,c.strokeStyle,c.lineWidth,c.lineCap,c.lineJoin,c.miterLimit,c.lineDash,c.lineDashOffset,!0,1],[1]);var c=a.Sb(),d=a.ia(),e=a.sa(),f=0,g,h;g=0;for(h=c.length;g<h;++g)f=ct(this,d,f,c[g],e);this.b.push([12]);$s(this,b)}};k.Se=function(){this.g.$f!=this.coordinates.length&&this.a.push([12]);Zs(this);this.g=null};
k.Na=function(a,b){var c=b.a;this.g.strokeStyle=fd(c?c:Rh);c=b.i;this.g.lineCap=void 0!==c?c:"round";c=b.g;this.g.lineDash=c?c:Qh;c=b.f;this.g.lineDashOffset=c?c:0;c=b.j;this.g.lineJoin=void 0!==c?c:"round";c=b.c;this.g.lineWidth=void 0!==c?c:1;c=b.l;this.g.miterLimit=void 0!==c?c:10;this.g.lineWidth>this.c&&(this.c=this.g.lineWidth,this.f=null)};function et(a,b,c,d){Vs.call(this,a,b,c,d);this.f=null;this.g={gh:void 0,Nd:void 0,Hd:void 0,Id:null,Jd:void 0,Kd:void 0,Ld:void 0,Md:void 0,fillStyle:void 0,strokeStyle:void 0,lineCap:void 0,lineDash:null,lineDashOffset:void 0,lineJoin:void 0,lineWidth:void 0,miterLimit:void 0}}u(et,Vs);
function ft(a,b,c,d,e){var f=a.g,g=void 0!==f.fillStyle,f=void 0!=f.strokeStyle,h=d.length,l=[1];a.a.push(l);a.b.push(l);for(l=0;l<h;++l){var m=d[l],n=a.coordinates.length;c=Ws(a,b,c,m,e,!0,!f);c=[8,n,c];a.a.push(c);a.b.push(c);f&&(c=[3],a.a.push(c),a.b.push(c));c=m}b=[7];a.b.push(b);g&&a.a.push(b);f&&(g=[12],a.a.push(g),a.b.push(g));return c}k=et.prototype;
k.ac=function(a,b){var c=this.g,d=c.strokeStyle;if(void 0!==c.fillStyle||void 0!==d){gt(this,a);Xs(this,b);this.b.push([9,dd(Ph)]);void 0!==c.strokeStyle&&this.b.push([10,c.strokeStyle,c.lineWidth,c.lineCap,c.lineJoin,c.miterLimit,c.lineDash,c.lineDashOffset,!0,1]);var e=a.ia(),d=this.coordinates.length;Ws(this,e,0,e.length,a.sa(),!1,!1);e=[1];d=[2,d];this.a.push(e,d);this.b.push(e,d);d=[7];this.b.push(d);void 0!==c.fillStyle&&this.a.push(d);void 0!==c.strokeStyle&&(c=[12],this.a.push(c),this.b.push(c));
$s(this,b)}};k.tc=function(a,b){var c=this.g;gt(this,a);Xs(this,b);this.b.push([9,dd(Ph)]);void 0!==c.strokeStyle&&this.b.push([10,c.strokeStyle,c.lineWidth,c.lineCap,c.lineJoin,c.miterLimit,c.lineDash,c.lineDashOffset,!0,1]);var c=a.Sb(),d=a.gc();ft(this,d,0,c,a.sa());$s(this,b)};
k.rc=function(a,b){var c=this.g,d=c.strokeStyle;if(void 0!==c.fillStyle||void 0!==d){gt(this,a);Xs(this,b);this.b.push([9,dd(Ph)]);void 0!==c.strokeStyle&&this.b.push([10,c.strokeStyle,c.lineWidth,c.lineCap,c.lineJoin,c.miterLimit,c.lineDash,c.lineDashOffset,!0,1]);var c=a.c,d=ci(a),e=a.sa(),f=0,g,h;g=0;for(h=c.length;g<h;++g)f=ft(this,d,f,c[g],e);$s(this,b)}};k.Se=function(){Zs(this);this.g=null;var a=this.na;if(a){var b=this.coordinates,c,d;c=0;for(d=b.length;c<d;++c)b[c]=a*Math.round(b[c]/a)}};
k.Nf=function(){this.f||(this.f=Oa(this.T),0<this.c&&Ma(this.f,this.resolution*(this.c+1)/2,this.f));return this.f};
k.Na=function(a,b){var c=this.g;if(a){var d=a.b;c.fillStyle=fd(d?d:Ph)}else c.fillStyle=void 0;b?(d=b.a,c.strokeStyle=fd(d?d:Rh),d=b.i,c.lineCap=void 0!==d?d:"round",d=b.g,c.lineDash=d?d.slice():Qh,d=b.f,c.lineDashOffset=d?d:0,d=b.j,c.lineJoin=void 0!==d?d:"round",d=b.c,c.lineWidth=void 0!==d?d:1,d=b.l,c.miterLimit=void 0!==d?d:10,c.lineWidth>this.c&&(this.c=c.lineWidth,this.f=null)):(c.strokeStyle=void 0,c.lineCap=void 0,c.lineDash=null,c.lineDashOffset=void 0,c.lineJoin=void 0,c.lineWidth=void 0,
c.miterLimit=void 0)};function gt(a,b){var c=a.g,d=c.fillStyle,e=c.strokeStyle,f=c.lineCap,g=c.lineDash,h=c.lineDashOffset,l=c.lineJoin,m=c.lineWidth,n=c.miterLimit;if(void 0!==d&&("string"!==typeof d||c.gh!=d)){var p=[9,d];"string"!==typeof d&&(d=b.D(),p.push([d[0],d[3]]));a.a.push(p);c.gh=c.fillStyle}void 0===e||c.Nd==e&&c.Hd==f&&ja(c.Id,g)&&c.Jd==h&&c.Kd==l&&c.Ld==m&&c.Md==n||(a.a.push([10,e,m,f,l,n,g,h,!0,1]),c.Nd=e,c.Hd=f,c.Id=g,c.Jd=h,c.Kd=l,c.Ld=m,c.Md=n)};function ht(a,b,c,d){Vs.call(this,a,b,c,d);this.G=this.C=this.A=null;this.Fa="";this.o=this.l=0;this.u=void 0;this.O=this.v=0;this.j=this.f=this.g=null}u(ht,Vs);
ht.prototype.Ac=function(a,b,c,d,e,f){if(""!==this.Fa&&this.j&&(this.g||this.f)){if(this.g){e=this.g;var g=this.A;if(!g||g.fillStyle!=e.fillStyle){var h=[9,e.fillStyle];this.a.push(h);this.b.push(h);g?g.fillStyle=e.fillStyle:this.A={fillStyle:e.fillStyle}}}this.f&&(e=this.f,g=this.C,g&&g.lineCap==e.lineCap&&g.lineDash==e.lineDash&&g.lineDashOffset==e.lineDashOffset&&g.lineJoin==e.lineJoin&&g.lineWidth==e.lineWidth&&g.miterLimit==e.miterLimit&&g.strokeStyle==e.strokeStyle||(h=[10,e.strokeStyle,e.lineWidth,
e.lineCap,e.lineJoin,e.miterLimit,e.lineDash,e.lineDashOffset,!1,1],this.a.push(h),this.b.push(h),g?(g.lineCap=e.lineCap,g.lineDash=e.lineDash,g.lineDashOffset=e.lineDashOffset,g.lineJoin=e.lineJoin,g.lineWidth=e.lineWidth,g.miterLimit=e.miterLimit,g.strokeStyle=e.strokeStyle):this.C={lineCap:e.lineCap,lineDash:e.lineDash,lineDashOffset:e.lineDashOffset,lineJoin:e.lineJoin,lineWidth:e.lineWidth,miterLimit:e.miterLimit,strokeStyle:e.strokeStyle}));e=this.j;g=this.G;g&&g.font==e.font&&g.textAlign==
e.textAlign&&g.textBaseline==e.textBaseline||(h=[11,e.font,e.textAlign,e.textBaseline],this.a.push(h),this.b.push(h),g?(g.font=e.font,g.textAlign=e.textAlign,g.textBaseline=e.textBaseline):this.G={font:e.font,textAlign:e.textAlign,textBaseline:e.textBaseline});Xs(this,f);e=this.coordinates.length;a=Ws(this,a,b,c,d,!1,!1);a=[5,e,a,this.Fa,this.l,this.o,this.v,this.O,!!this.g,!!this.f,this.u];this.a.push(a);this.b.push(a);$s(this,f)}};
ht.prototype.Ub=function(a){if(a){var b=a.Ca();b?(b=b.b,b=fd(b?b:Ph),this.g?this.g.fillStyle=b:this.g={fillStyle:b}):this.g=null;var c=a.Da();if(c){var b=c.a,d=c.i,e=c.g,f=c.f,g=c.j,h=c.c,c=c.l,d=void 0!==d?d:"round",e=e?e.slice():Qh,f=void 0!==f?f:0,g=void 0!==g?g:"round",h=void 0!==h?h:1,c=void 0!==c?c:10,b=fd(b?b:Rh);if(this.f){var l=this.f;l.lineCap=d;l.lineDash=e;l.lineDashOffset=f;l.lineJoin=g;l.lineWidth=h;l.miterLimit=c;l.strokeStyle=b}else this.f={lineCap:d,lineDash:e,lineDashOffset:f,lineJoin:g,
lineWidth:h,miterLimit:c,strokeStyle:b}}else this.f=null;var m=a.a,b=a.g,d=a.c,e=a.l,h=a.i,c=a.b,f=a.Oa(),g=a.f,l=a.j;a=void 0!==m?m:"10px sans-serif";g=void 0!==g?g:"center";l=void 0!==l?l:"middle";this.j?(m=this.j,m.font=a,m.textAlign=g,m.textBaseline=l):this.j={font:a,textAlign:g,textBaseline:l};this.Fa=void 0!==f?f:"";this.l=void 0!==b?b:0;this.o=void 0!==d?d:0;this.u=void 0!==e?e:!1;this.v=void 0!==h?h:0;this.O=void 0!==c?c:1}else this.Fa=""};function it(a,b,c,d,e){this.v=a;this.c=b;this.o=d;this.u=c;this.f=e;this.a={};this.j=hd(1,1);this.l=yh()}u(it,hi);var jt={0:[[!0]]};function kt(a,b,c){var d,e=Math.floor(a.length/2);if(b>=e)for(d=e;d<b;d++)a[d][c]=!0;else if(b<e)for(d=b+1;d<e;d++)a[d][c]=!0}
function lt(a){if(void 0!==jt[a])return jt[a];for(var b=2*a+1,c=Array(b),d=0;d<b;d++)c[d]=Array(b);for(var b=a,e=d=0;b>=d;)kt(c,a+b,a+d),kt(c,a+d,a+b),kt(c,a-d,a+b),kt(c,a-b,a+d),kt(c,a-b,a-d),kt(c,a-d,a-b),kt(c,a+d,a-b),kt(c,a+b,a-d),d++,e+=1+2*d,0<2*(e-b)+1&&(--b,e+=1-2*b);return jt[a]=c}function mt(a){for(var b in a.a){var c=a.a[b],d;for(d in c)c[d].Se()}}
it.prototype.Ba=function(a,b,c,d,e,f){d=Math.round(d);var g=2*d+1,h=Hh(this.l,d+.5,d+.5,1/b,-1/b,-c,-a[0],-a[1]),l=this.j;l.canvas.width!==g||l.canvas.height!==g?(l.canvas.width=g,l.canvas.height=g):l.clearRect(0,0,g,g);var m;void 0!==this.f&&(m=Ja(),La(m,a),Ma(m,b*(this.f+d),m));var n=lt(d);return nt(this,l,h,c,e,function(a){for(var b=l.getImageData(0,0,g,g).data,c=0;c<g;c++)for(var d=0;d<g;d++)if(n[c][d]&&0<b[4*(d*g+c)+3]){if(a=f(a))return a;l.clearRect(0,0,g,g);return}},m)};
function ot(a,b){var c=a.c,d=c[0],e=c[1],f=c[2],c=c[3],d=[d,e,d,c,f,c,f,e];mf(d,0,8,2,b,d);return d}it.prototype.b=function(a,b){var c=void 0!==a?a.toString():"0",d=this.a[c];void 0===d&&(d={},this.a[c]=d);c=d[b];void 0===c&&(c=new pt[b](this.v,this.c,this.u,this.o),d[b]=c);return c};it.prototype.g=function(){return tb(this.a)};
it.prototype.i=function(a,b,c,d,e,f){var g=Object.keys(this.a).map(Number);g.sort(ea);var h=ot(this,c);a.save();a.beginPath();a.moveTo(h[0],h[1]);a.lineTo(h[2],h[3]);a.lineTo(h[4],h[5]);a.lineTo(h[6],h[7]);a.clip();f=f?f:gi;var l,m,n,p,q,h=0;for(l=g.length;h<l;++h)for(p=this.a[g[h].toString()],m=0,n=f.length;m<n;++m)q=p[f[m]],void 0!==q&&q.i(a,b,c,d,e);a.restore()};
function nt(a,b,c,d,e,f,g){var h=Object.keys(a.a).map(Number);h.sort(function(a,b){return b-a});var l,m,n,p,q;l=0;for(m=h.length;l<m;++l)for(p=a.a[h[l].toString()],n=gi.length-1;0<=n;--n)if(q=p[gi[n]],void 0!==q&&(q=Ys(q,b,1,c,d,e,q.b,f,g)))return q}var pt={Circle:et,Image:at,LineString:bt,Polygon:et,Text:ht};function qt(a){Pc.call(this);this.a=a}u(qt,Pc);qt.prototype.Ba=oa;qt.prototype.Te=kf;qt.prototype.Jf=function(a,b,c){return function(d,e){return rt(a,b,d,e,function(a){c[d]||(c[d]={});c[d][a.Ga.toString()]=a})}};qt.prototype.ea=function(a){2===a.target.V()&&st(this)};function tt(a,b){var c=b.V();2!=c&&3!=c&&z(b,"change",a.ea,a);0==c&&(b.load(),c=b.V());return 2==c}function st(a){var b=a.a;b.Lb()&&"ready"==b.Vf()&&a.s()}
function ut(a,b){b.Ei()&&a.postRenderFunctions.push(function(a,b,e){b=w(a).toString();a.ld(e.viewState.projection,e.usedTiles[b])}.bind(null,b))}function vt(a,b){if(b){var c,d,e;d=0;for(e=b.length;d<e;++d)c=b[d],a[w(c).toString()]=c}}function wt(a,b){var c=b.Z;void 0!==c&&("string"===typeof c?a.logos[c]="":c&&(sa("string"==typeof c.href,44),sa("string"==typeof c.src,45),a.logos[c.src]=c.href))}
function xt(a,b,c,d){b=w(b).toString();c=c.toString();b in a?c in a[b]?(a=a[b][c],d.da<a.da&&(a.da=d.da),d.ba>a.ba&&(a.ba=d.ba),d.ga<a.ga&&(a.ga=d.ga),d.ja>a.ja&&(a.ja=d.ja)):a[b][c]=d:(a[b]={},a[b][c]=d)}
function yt(a,b,c,d,e,f,g,h,l,m){var n=w(b).toString();n in a.wantedTiles||(a.wantedTiles[n]={});var p=a.wantedTiles[n];a=a.tileQueue;var q=c.minZoom,r,v,x,y,A,B;for(B=g;B>=q;--B)for(v=nc(c,f,B,v),x=c.La(B),y=v.da;y<=v.ba;++y)for(A=v.ga;A<=v.ja;++A)g-B<=h?(r=b.Pc(B,y,A,d,e),0==r.V()&&(p[r.hb()]=!0,r.hb()in a.a||a.i([r,n,sc(c,r.Ga),x])),l&&l.call(m,r)):b.Mg(B,y,A,e)};function zt(a){qt.call(this,a);this.fa=yh()}u(zt,qt);function At(a,b,c){var d=b.pixelRatio,e=b.size[0]*d,f=b.size[1]*d,g=b.viewState.rotation,h=fb(c),l=eb(c),m=db(c);c=cb(c);Dh(b.coordinateToPixelTransform,h);Dh(b.coordinateToPixelTransform,l);Dh(b.coordinateToPixelTransform,m);Dh(b.coordinateToPixelTransform,c);a.save();Sh(a,-g,e/2,f/2);a.beginPath();a.moveTo(h[0]*d,h[1]*d);a.lineTo(l[0]*d,l[1]*d);a.lineTo(m[0]*d,m[1]*d);a.lineTo(c[0]*d,c[1]*d);a.clip();Sh(a,g,e/2,f/2)}
function Bt(a,b,c,d,e){var f=a.a;if(Oc(f,b)){var g=d.size[0]*d.pixelRatio,h=d.size[1]*d.pixelRatio,l=d.viewState.rotation;Sh(c,-l,g/2,h/2);a=e?e:Ct(a,d,0);f.b(new Oh(b,new Uh(c,d.pixelRatio,d.extent,a,d.viewState.rotation),d,c,null));Sh(c,l,g/2,h/2)}}zt.prototype.v=function(a,b,c,d){if(this.Ba(a,b,0,jf,this))return c.call(d,this.a,null)};zt.prototype.cf=function(a,b,c,d){Bt(this,"postcompose",a,b,d)};
function Ct(a,b,c){var d=b.viewState,e=b.pixelRatio,f=e/d.resolution;return Hh(a.fa,e*b.size[0]/2,e*b.size[1]/2,f,-f,-d.rotation,-d.center[0]+c,-d.center[1])};function Dt(a,b){return w(a)-w(b)}function Et(a,b){var c=.5*a/b;return c*c}function Ft(a,b,c,d,e,f){var g=!1,h,l;if(h=c.Y())l=h.Xe(),2==l||3==l?h.xj(e,f):(0==l&&h.load(),h.Gh(e,f),g=!0);if(e=(0,c.Qa)(b))d=e.Td(d),(0,Gt[d.S()])(a,d,c,b);return g}
var Gt={Point:function(a,b,c,d){var e=c.Y();if(e){if(2!=e.Xe())return;var f=a.b(c.Aa(),"Image");f.Wb(e);f.sc(b,d)}if(e=c.Oa())a=a.b(c.Aa(),"Text"),a.Ub(e),a.Ac(b.ia(),0,2,2,b,d)},LineString:function(a,b,c,d){var e=c.Da();if(e){var f=a.b(c.Aa(),"LineString");f.Na(null,e);f.Rb(b,d)}if(e=c.Oa())a=a.b(c.Aa(),"Text"),a.Ub(e),a.Ac(ai(b),0,2,2,b,d)},Polygon:function(a,b,c,d){var e=c.Ca(),f=c.Da();if(e||f){var g=a.b(c.Aa(),"Polygon");g.Na(e,f);g.tc(b,d)}if(e=c.Oa())a=a.b(c.Aa(),"Text"),a.Ub(e),a.Ac(Tf(b),
0,2,2,b,d)},MultiPoint:function(a,b,c,d){var e=c.Y();if(e){if(2!=e.Xe())return;var f=a.b(c.Aa(),"Image");f.Wb(e);f.qc(b,d)}if(e=c.Oa())a=a.b(c.Aa(),"Text"),a.Ub(e),c=b.ia(),a.Ac(c,0,c.length,b.sa(),b,d)},MultiLineString:function(a,b,c,d){var e=c.Da();if(e){var f=a.b(c.Aa(),"LineString");f.Na(null,e);f.pc(b,d)}if(e=c.Oa())a=a.b(c.Aa(),"Text"),a.Ub(e),c=bi(b),a.Ac(c,0,c.length,2,b,d)},MultiPolygon:function(a,b,c,d){var e=c.Ca(),f=c.Da();if(f||e){var g=a.b(c.Aa(),"Polygon");g.Na(e,f);g.rc(b,d)}if(e=
c.Oa())a=a.b(c.Aa(),"Text"),a.Ub(e),c=di(b),a.Ac(c,0,c.length,2,b,d)},GeometryCollection:function(a,b,c,d){b=b.a;var e,f;e=0;for(f=b.length;e<f;++e)(0,Gt[b[e].S()])(a,b[e],c,d)},Circle:function(a,b,c,d){var e=c.Ca(),f=c.Da();if(e||f){var g=a.b(c.Aa(),"Circle");g.Na(e,f);g.ac(b,d)}if(e=c.Oa())a=a.b(c.Aa(),"Text"),a.Ub(e),a.Ac(b.za(),0,2,2,b,d)}};function Ht(a){zt.call(this,a);this.c=!1;this.u=-1;this.o=NaN;this.j=Ja();this.i=this.l=null;this.f=hd()}u(Ht,zt);
Ht.prototype.O=function(a,b,c){var d=a.extent,e=a.pixelRatio,f=b.Ie?a.skippedFeatureUids:{},g=a.viewState,h=g.projection,g=g.rotation,l=h.D(),m=this.a.ka(),n=Ct(this,a,0);Bt(this,"precompose",c,a,n);var p=b.extent,q=void 0!==p;q&&At(c,a,p);if((p=this.i)&&!p.g()){var r=0,v=0,x;if(Oc(this.a,"render")){x=c.canvas.width;var y=c.canvas.height;if(g){var A=Math.round(Math.sqrt(x*x+y*y)),r=(A-x)/2,v=(A-y)/2;x=y=A}this.f.canvas.width=x;this.f.canvas.height=y;x=this.f}else x=c;y=x.globalAlpha;x.globalAlpha=
b.opacity;x!=c&&x.translate(r,v);var A=a.size[0]*e,B=a.size[1]*e;Sh(x,-g,A/2,B/2);p.i(x,e,n,g,f);if(m.G&&h.a&&!Ua(l,d)){for(var h=d[0],m=ib(l),aa=0;h<l[0];)--aa,n=m*aa,n=Ct(this,a,n),p.i(x,e,n,g,f),h+=m;aa=0;for(h=d[2];h>l[2];)++aa,n=m*aa,n=Ct(this,a,n),p.i(x,e,n,g,f),h-=m;n=Ct(this,a,0)}Sh(x,g,A/2,B/2);x!=c&&(Bt(this,"render",x,a,n),c.drawImage(x.canvas,-r,-v),x.translate(-r,-v));x.globalAlpha=y}q&&c.restore();this.cf(c,a,b,n)};
Ht.prototype.Ba=function(a,b,c,d,e){if(this.i){var f=this.a,g={};return this.i.Ba(a,b.viewState.resolution,b.viewState.rotation,c,{},function(a){var b=w(a).toString();if(!(b in g))return g[b]=!0,d.call(e,a,f)})}};Ht.prototype.A=function(){st(this)};
Ht.prototype.ud=function(a){function b(a){var b,d=a.Rc();d?b=d.call(a,m):(d=c.i)&&(b=d(a,m));if(b){if(b){d=!1;if(Array.isArray(b))for(var e=0,f=b.length;e<f;++e)d=Ft(q,a,b[e],Et(m,n),this.A,this)||d;else d=Ft(q,a,b,Et(m,n),this.A,this)||d;a=d}else a=!1;this.c=this.c||a}}var c=this.a,d=c.ka();vt(a.attributions,d.j);wt(a,d);var e=a.viewHints[0],f=a.viewHints[1],g=c.ea,h=c.fa;if(!this.c&&!g&&e||!h&&f)return!0;var l=a.extent,h=a.viewState,e=h.projection,m=h.resolution,n=a.pixelRatio,f=c.g,p=c.c,g=c.get(It);
void 0===g&&(g=Dt);l=Ma(l,p*m);p=h.projection.D();d.G&&h.projection.a&&!Ua(p,a.extent)&&(a=Math.max(ib(l)/2,ib(p)),l[0]=p[0]-a,l[2]=p[2]+a);if(!this.c&&this.o==m&&this.u==f&&this.l==g&&Ua(this.j,l))return!0;this.i=null;this.c=!1;var q=new it(.5*m/n,l,m,d.Ha,c.c);d.Xd(l,m,e);if(g){var r=[];d.bc(l,function(a){r.push(a)},this);r.sort(g);r.forEach(b,this)}else d.bc(l,b,this);mt(q);this.o=m;this.u=f;this.l=g;this.j=l;this.i=q;return!0};function Jt(){this.b="precision mediump float;varying vec2 a;uniform float f;uniform sampler2D g;void main(void){vec4 texColor=texture2D(g,a);gl_FragColor.rgb=texColor.rgb;gl_FragColor.a=texColor.a*f;}"}u(Jt,ji);var Kt=new Jt;function Lt(){this.b="varying vec2 a;attribute vec2 b;attribute vec2 c;uniform mat4 d;uniform mat4 e;void main(void){gl_Position=e*vec4(b,0.,1.);a=(d*vec4(c,0.,1.)).st;}"}u(Lt,ki);var Mt=new Lt;
function Nt(a,b){this.g=a.getUniformLocation(b,"f");this.c=a.getUniformLocation(b,"e");this.f=a.getUniformLocation(b,"d");this.i=a.getUniformLocation(b,"g");this.b=a.getAttribLocation(b,"b");this.a=a.getAttribLocation(b,"c")};function Ot(a,b){qt.call(this,b);this.c=a;this.T=new Ai([-1,-1,0,0,1,-1,1,0,-1,1,0,1,1,1,1,1]);this.f=this.Fb=null;this.j=void 0;this.u=yh();this.O=yh();this.C=qi();this.v=null}u(Ot,qt);
function Pt(a,b,c){var d=a.c.g;if(void 0===a.j||a.j!=c){b.postRenderFunctions.push(function(a,b,c){a.isContextLost()||(a.deleteFramebuffer(b),a.deleteTexture(c))}.bind(null,d,a.f,a.Fb));b=Ni(d,c,c);var e=d.createFramebuffer();d.bindFramebuffer(36160,e);d.framebufferTexture2D(36160,36064,3553,b,0);a.Fb=b;a.f=e;a.j=c}else d.bindFramebuffer(36160,a.f)}
Ot.prototype.zi=function(a,b,c){Qt(this,"precompose",c,a);ti(c,34962,this.T);var d=c.b,e=Ei(c,Kt,Mt),f;this.v?f=this.v:this.v=f=new Nt(d,e);c.Vc(e)&&(d.enableVertexAttribArray(f.b),d.vertexAttribPointer(f.b,2,5126,!1,16,0),d.enableVertexAttribArray(f.a),d.vertexAttribPointer(f.a,2,5126,!1,16,8),d.uniform1i(f.i,0));d.uniformMatrix4fv(f.f,!1,ri(this.C,this.u));d.uniformMatrix4fv(f.c,!1,ri(this.C,this.O));d.uniform1f(f.g,b.opacity);d.bindTexture(3553,this.Fb);d.drawArrays(5,0,4);Qt(this,"postcompose",
c,a)};function Qt(a,b,c,d){a=a.a;if(Oc(a,b)){var e=d.viewState;a.b(new Oh(b,new kk(c,e.center,e.resolution,e.rotation,d.size,d.extent,d.pixelRatio),d,null,c))}}Ot.prototype.hg=function(){this.f=this.Fb=null;this.j=void 0};function Rt(a,b){Ot.call(this,a,b);this.o=!1;this.Z=-1;this.I=NaN;this.A=Ja();this.l=this.i=this.G=null}u(Rt,Ot);k=Rt.prototype;k.zi=function(a,b,c){this.l=b;var d=a.viewState,e=this.i,f=a.size,g=a.pixelRatio,h=this.c.g;e&&!e.g()&&(h.enable(h.SCISSOR_TEST),h.scissor(0,0,f[0]*g,f[1]*g),e.i(c,d.center,d.resolution,d.rotation,f,g,b.opacity,b.Ie?a.skippedFeatureUids:{}),h.disable(h.SCISSOR_TEST))};k.ra=function(){var a=this.i;a&&(ek(a,this.c.i)(),this.i=null);Ot.prototype.ra.call(this)};
k.Ba=function(a,b,c,d,e){if(this.i&&this.l){c=b.viewState;var f=this.a,g={};return this.i.Ba(a,this.c.i,c.center,c.resolution,c.rotation,b.size,b.pixelRatio,this.l.opacity,{},function(a){var b=w(a).toString();if(!(b in g))return g[b]=!0,d.call(e,a,f)})}};k.Te=function(a,b){if(this.i&&this.l){var c=b.viewState;return jk(this.i,a,this.c.i,c.resolution,c.rotation,b.pixelRatio,this.l.opacity,b.skippedFeatureUids)}return!1};
k.gg=function(a,b,c,d){a=Dh(b.pixelToCoordinateTransform,a.slice());if(this.Te(a,b))return c.call(d,this.a,null)};k.Ai=function(){st(this)};
k.ig=function(a,b,c){function d(a){var b,c=a.Rc();c?b=c.call(a,m):(c=e.i)&&(b=c(a,m));if(b){if(b){c=!1;if(Array.isArray(b))for(var d=b.length-1;0<=d;--d)c=Ft(q,a,b[d],Et(m,n),this.Ai,this)||c;else c=Ft(q,a,b,Et(m,n),this.Ai,this)||c;a=c}else a=!1;this.o=this.o||a}}var e=this.a;b=e.ka();vt(a.attributions,b.j);wt(a,b);var f=a.viewHints[0],g=a.viewHints[1],h=e.ea,l=e.fa;if(!this.o&&!h&&f||!l&&g)return!0;var g=a.extent,h=a.viewState,f=h.projection,m=h.resolution,n=a.pixelRatio,h=e.g,p=e.c,l=e.get(It);
void 0===l&&(l=Dt);g=Ma(g,p*m);if(!this.o&&this.I==m&&this.Z==h&&this.G==l&&Ua(this.A,g))return!0;this.i&&a.postRenderFunctions.push(ek(this.i,c));this.o=!1;var q=new dk(.5*m/n,g,e.c);b.Xd(g,m,f);if(l){var r=[];b.bc(g,function(a){r.push(a)},this);r.sort(l);r.forEach(d,this)}else b.bc(g,d,this);fk(q,c);this.I=m;this.Z=h;this.G=l;this.A=g;this.i=q;return!0};function S(a){a=a?a:{};var b=qb({},a);delete b.style;delete b.renderBuffer;delete b.updateWhileAnimating;delete b.updateWhileInteracting;th.call(this,b);this.c=void 0!==a.renderBuffer?a.renderBuffer:100;this.A=null;this.i=void 0;this.f(a.style);this.ea=void 0!==a.updateWhileAnimating?a.updateWhileAnimating:!1;this.fa=void 0!==a.updateWhileInteracting?a.updateWhileInteracting:!1}u(S,th);S.prototype.Gd=function(a){var b=null,c=a.S();"canvas"===c?b=new Ht(this):"webgl"===c&&(b=new Rt(a,this));return b};
S.prototype.C=function(){return this.A};S.prototype.G=function(){return this.i};S.prototype.f=function(a){this.A=void 0!==a?a:fl;this.i=null===a?void 0:dl(this.A);this.s()};var It="renderOrder";function St(){return[[-Infinity,-Infinity,Infinity,Infinity]]};function Tt(a){Qc.call(this);this.c=Tb(a.projection);this.j=Ut(a.attributions);this.Z=a.logo;this.Ja=void 0!==a.state?a.state:"ready";this.G=void 0!==a.wrapX?a.wrapX:!1}u(Tt,Qc);function Ut(a){if("string"===typeof a)return[new xc({html:a})];if(a instanceof xc)return[a];if(Array.isArray(a)){for(var b=a.length,c=Array(b),d=0;d<b;d++){var e=a[d];c[d]="string"===typeof e?new xc({html:e}):e}return c}return null}k=Tt.prototype;k.Ba=oa;k.xa=function(){return this.j};k.wa=function(){return this.Z};k.ya=function(){return this.c};
k.V=function(){return this.Ja};k.va=function(){this.s()};k.ua=function(a){this.j=Ut(a);this.s()};function Vt(a,b){a.Ja=b;a.s()};function T(a){a=a||{};Tt.call(this,{attributions:a.attributions,logo:a.logo,projection:void 0,state:"ready",wrapX:void 0!==a.wrapX?a.wrapX:!0});this.ea=oa;this.T=a.format;this.Ha=void 0==a.overlaps?!0:a.overlaps;this.fa=a.url;a.loader?this.ea=a.loader:void 0!==this.fa&&(sa(this.T,7),this.ea=Dl(this.fa,this.T));this.Va=a.strategy?a.strategy:St;var b=void 0!==a.useSpatialIndex?a.useSpatialIndex:!0;this.a=b?new Gj:null;this.na=new Gj;this.f={};this.l={};this.o={};this.u={};this.i=null;var c,d;a.features instanceof
D?(c=a.features,d=c.a):Array.isArray(a.features)&&(d=a.features);b||c||(c=new D(d));d&&Wt(this,d);c&&Xt(this,c)}u(T,Tt);k=T.prototype;k.zb=function(a){var b=w(a).toString();if(Yt(this,b,a)){Zt(this,b,a);var c=a.U();c?(b=c.D(),this.a&&this.a.Ea(b,a)):this.f[b]=a;this.b(new $t("addfeature",a))}this.s()};function Zt(a,b,c){a.u[b]=[z(c,"change",a.Ii,a),z(c,"propertychange",a.Ii,a)]}
function Yt(a,b,c){var d=!0,e=c.a;void 0!==e?e.toString()in a.l?d=!1:a.l[e.toString()]=c:(sa(!(b in a.o),30),a.o[b]=c);return d}k.gd=function(a){Wt(this,a);this.s()};function Wt(a,b){var c,d,e,f,g=[],h=[],l=[];d=0;for(e=b.length;d<e;d++)f=b[d],c=w(f).toString(),Yt(a,c,f)&&h.push(f);d=0;for(e=h.length;d<e;d++){f=h[d];c=w(f).toString();Zt(a,c,f);var m=f.U();m?(c=m.D(),g.push(c),l.push(f)):a.f[c]=f}a.a&&a.a.load(g,l);d=0;for(e=h.length;d<e;d++)a.b(new $t("addfeature",h[d]))}
function Xt(a,b){var c=!1;z(a,"addfeature",function(a){c||(c=!0,b.push(a.feature),c=!1)});z(a,"removefeature",function(a){c||(c=!0,b.remove(a.feature),c=!1)});z(b,"add",function(a){c||(c=!0,this.zb(a.element),c=!1)},a);z(b,"remove",function(a){c||(c=!0,this.Db(a.element),c=!1)},a);a.i=b}
k.clear=function(a){if(a){for(var b in this.u)this.u[b].forEach(Bc);this.i||(this.u={},this.l={},this.o={})}else if(this.a){this.a.forEach(this.Cg,this);for(var c in this.f)this.Cg(this.f[c])}this.i&&this.i.clear();this.a&&this.a.clear();this.na.clear();this.f={};this.b(new $t("clear"));this.s()};k.kh=function(a,b){if(this.a)return this.a.forEach(a,b);if(this.i)return this.i.forEach(a,b)};function au(a,b,c){a.bc([b[0],b[1],b[0],b[1]],function(a){if(a.U().sb(b))return c.call(void 0,a)})}
k.bc=function(a,b,c){if(this.a)return Lj(this.a,a,b,c);if(this.i)return this.i.forEach(b,c)};k.lh=function(a,b,c){return this.bc(a,function(d){if(d.U().Ya(a)&&(d=b.call(c,d)))return d})};k.th=function(){return this.i};k.We=function(){var a;this.i?a=this.i.a:this.a&&(a=Ij(this.a),tb(this.f)||ha(a,sb(this.f)));return a};k.sh=function(a){var b=[];au(this,a,function(a){b.push(a)});return b};k.Pf=function(a){return Jj(this.a,a)};
k.oh=function(a,b){var c=a[0],d=a[1],e=null,f=[NaN,NaN],g=Infinity,h=[-Infinity,-Infinity,Infinity,Infinity],l=b?b:jf;Lj(this.a,h,function(a){if(l(a)){var b=a.U(),m=g;g=b.Hb(c,d,f,g);g<m&&(e=a,a=Math.sqrt(g),h[0]=c-a,h[1]=d-a,h[2]=c+a,h[3]=d+a)}});return e};k.D=function(a){return this.a.D(a)};k.rh=function(a){a=this.l[a.toString()];return void 0!==a?a:null};k.Gi=function(){return this.T};k.Hi=function(){return this.fa};
k.Ii=function(a){a=a.target;var b=w(a).toString(),c=a.U();c?(c=c.D(),b in this.f?(delete this.f[b],this.a&&this.a.Ea(c,a)):this.a&&Hj(this.a,c,a)):b in this.f||(this.a&&this.a.remove(a),this.f[b]=a);c=a.a;void 0!==c?(c=c.toString(),b in this.o?(delete this.o[b],this.l[c]=a):this.l[c]!==a&&(bu(this,a),this.l[c]=a)):b in this.o||(bu(this,a),this.o[b]=a);this.s();this.b(new $t("changefeature",a))};
k.Xd=function(a,b,c){var d=this.na;a=this.Va(a,b);var e,f;e=0;for(f=a.length;e<f;++e){var g=a[e];Lj(d,g,function(a){return Ua(a.extent,g)})||(this.ea.call(this,g,b,c),d.Ea(g,{extent:g.slice()}))}};k.Db=function(a){var b=w(a).toString();b in this.f?delete this.f[b]:this.a&&this.a.remove(a);this.Cg(a);this.s()};k.Cg=function(a){var b=w(a).toString();this.u[b].forEach(Bc);delete this.u[b];var c=a.a;void 0!==c?delete this.l[c.toString()]:delete this.o[b];this.b(new $t("removefeature",a))};
function bu(a,b){for(var c in a.l)if(a.l[c]===b){delete a.l[c];break}}function $t(a,b){Lc.call(this,a);this.feature=b}u($t,Lc);function cu(a){Ag.call(this,{handleDownEvent:du,handleEvent:eu,handleUpEvent:fu});this.T=!1;this.fa=null;this.u=!1;this.Gb=a.source?a.source:null;this.Va=a.features?a.features:null;this.sk=a.snapTolerance?a.snapTolerance:12;this.Z=a.type;this.f=gu(this.Z);this.Ha=a.minPoints?a.minPoints:this.f===hu?3:2;this.Ja=a.maxPoints?a.maxPoints:Infinity;this.yf=a.finishCondition?a.finishCondition:jf;var b=a.geometryFunction;if(!b)if("Circle"===this.Z)b=function(a,b){var c=b?b:new vs([NaN,NaN]);c.Gg(a[0],Math.sqrt(ef(a[0],
a[1])));return c};else{var c,d=this.f;d===iu?c=E:d===ju?c=N:d===hu&&(c=F);b=function(a,b){var e=b;e?d===hu?e.pa([a[0].concat([a[0][0]])]):e.pa(a):e=new c(a);return e}}this.Qa=b;this.I=this.C=this.a=this.G=this.j=this.o=null;this.le=a.clickTolerance?a.clickTolerance*a.clickTolerance:36;this.na=new S({source:new T({useSpatialIndex:!1,wrapX:a.wrapX?a.wrapX:!1}),style:a.style?a.style:ku()});this.yb=a.geometryName;this.rk=a.condition?a.condition:vg;this.zf=a.freehand?jf:a.freehandCondition?a.freehandCondition:
wg;z(this,Sc("active"),this.ji,this)}u(cu,Ag);function ku(){var a=gl();return function(b){return a[b.U().S()]}}k=cu.prototype;k.setMap=function(a){Ag.prototype.setMap.call(this,a);this.ji()};function eu(a){this.u=this.f!==iu&&this.zf(a);var b=!this.u;this.u&&"pointerdrag"===a.type&&null!==this.j?(lu(this,a),b=!1):"pointermove"===a.type?b=mu(this,a):"dblclick"===a.type&&(b=!1);return Bg.call(this,a)&&b}
function du(a){this.T=!this.u;return this.u?(this.fa=a.pixel,this.o||nu(this,a),!0):this.rk(a)?(this.fa=a.pixel,!0):!1}function fu(a){var b=!0;mu(this,a);var c=this.f===ou;this.T?(this.o?this.u||c?this.Qd():pu(this,a)?this.yf(a)&&this.Qd():lu(this,a):(nu(this,a),this.f===iu&&this.Qd()),b=!1):this.u&&(this.o=null,qu(this));return b}
function mu(a,b){if(a.fa&&(!a.u&&a.T||a.u&&!a.T)){var c=a.fa,d=b.pixel,e=c[0]-d[0],c=c[1]-d[1],e=e*e+c*c;a.T=a.u?e>a.le:e<=a.le}a.o?(e=b.coordinate,c=a.j.U(),a.f===iu?d=a.a:a.f===hu?(d=a.a[0],d=d[d.length-1],pu(a,b)&&(e=a.o.slice())):(d=a.a,d=d[d.length-1]),d[0]=e[0],d[1]=e[1],a.Qa(a.a,c),a.G&&a.G.U().pa(e),c instanceof F&&a.f!==hu?(a.C||(a.C=new I(new N(null))),c=c.vh(0),e=a.C.U(),e.ca(c.la,c.ia())):a.I&&(e=a.C.U(),e.pa(a.I)),ru(a)):(e=b.coordinate.slice(),a.G?a.G.U().pa(e):(a.G=new I(new E(e)),
ru(a)));return!0}function pu(a,b){var c=!1;if(a.j){var d=!1,e=[a.o];a.f===ju?d=a.a.length>a.Ha:a.f===hu&&(d=a.a[0].length>a.Ha,e=[a.a[0][0],a.a[0][a.a[0].length-2]]);if(d)for(var d=b.map,f=0,g=e.length;f<g;f++){var h=e[f],l=d.Ka(h),m=b.pixel,c=m[0]-l[0],l=m[1]-l[1];if(c=Math.sqrt(c*c+l*l)<=(a.u?1:a.sk)){a.o=h;break}}}return c}
function nu(a,b){var c=b.coordinate;a.o=c;a.f===iu?a.a=c.slice():a.f===hu?(a.a=[[c.slice(),c.slice()]],a.I=a.a[0]):(a.a=[c.slice(),c.slice()],a.f===ou&&(a.I=a.a));a.I&&(a.C=new I(new N(a.I)));c=a.Qa(a.a);a.j=new I;a.yb&&a.j.Yc(a.yb);a.j.Ta(c);ru(a);a.b(new su("drawstart",a.j))}
function lu(a,b){var c=b.coordinate,d=a.j.U(),e,f;a.f===ju?(a.o=c.slice(),f=a.a,f.length>=a.Ja&&(a.u?f.pop():e=!0),f.push(c.slice()),a.Qa(f,d)):a.f===hu&&(f=a.a[0],f.length>=a.Ja&&(a.u?f.pop():e=!0),f.push(c.slice()),e&&(a.o=f[0]),a.Qa(a.a,d));ru(a);e&&a.Qd()}
k.Ep=function(){if(this.j){var a=this.j.U(),b,c;this.f===ju?(b=this.a,b.splice(-2,1),this.Qa(b,a),2<=b.length&&(this.o=b[b.length-2].slice())):this.f===hu&&(b=this.a[0],b.splice(-2,1),c=this.C.U(),c.pa(b),this.Qa(this.a,a));0===b.length&&(this.o=null);ru(this)}};
k.Qd=function(){var a=qu(this),b=this.a,c=a.U();this.f===ju?(b.pop(),this.Qa(b,c)):this.f===hu&&(b[0].pop(),this.Qa(b,c),b=c.W());"MultiPoint"===this.Z?a.Ta(new P([b])):"MultiLineString"===this.Z?a.Ta(new O([b])):"MultiPolygon"===this.Z&&a.Ta(new Q([b]));this.b(new su("drawend",a));this.Va&&this.Va.push(a);this.Gb&&this.Gb.zb(a)};function qu(a){a.o=null;var b=a.j;b&&(a.j=null,a.G=null,a.C=null,a.na.ka().clear(!0));return b}
k.nn=function(a){var b=a.U();this.j=a;this.a=b.W();a=this.a[this.a.length-1];this.o=a.slice();this.a.push(a.slice());ru(this);this.b(new su("drawstart",this.j))};k.bd=kf;function ru(a){var b=[];a.j&&b.push(a.j);a.C&&b.push(a.C);a.G&&b.push(a.G);a=a.na.ka();a.clear(!0);a.gd(b)}k.ji=function(){var a=this.v,b=this.c();a&&b||qu(this);this.na.setMap(b?a:null)};
function gu(a){var b;"Point"===a||"MultiPoint"===a?b=iu:"LineString"===a||"MultiLineString"===a?b=ju:"Polygon"===a||"MultiPolygon"===a?b=hu:"Circle"===a&&(b=ou);return b}var iu="Point",ju="LineString",hu="Polygon",ou="Circle";function su(a,b){Lc.call(this,a);this.feature=b}u(su,Lc);function tu(a){this.a=this.j=null;this.C=!1;this.G=this.o=null;a||(a={});a.extent&&this.f(a.extent);Ag.call(this,{handleDownEvent:uu,handleDragEvent:vu,handleEvent:wu,handleUpEvent:xu});this.u=new S({source:new T({useSpatialIndex:!1,wrapX:!!a.wrapX}),style:a.boxStyle?a.boxStyle:yu(),updateWhileAnimating:!0,updateWhileInteracting:!0});this.I=new S({source:new T({useSpatialIndex:!1,wrapX:!!a.wrapX}),style:a.pointerStyle?a.pointerStyle:zu(),updateWhileAnimating:!0,updateWhileInteracting:!0})}u(tu,Ag);
function wu(a){if(!(a instanceof Kd))return!0;if("pointermove"==a.type&&!this.A){var b=a.pixel,c=a.map,d=Au(this,b,c);d||(d=c.Xa(b));Bu(this,d)}Bg.call(this,a);return!1}
function uu(a){function b(a){var b=null,c=null;a[0]==e[0]?b=e[2]:a[0]==e[2]&&(b=e[0]);a[1]==e[1]?c=e[3]:a[1]==e[3]&&(c=e[1]);return null!==b&&null!==c?[b,c]:null}var c=a.pixel,d=a.map,e=this.D();(a=Au(this,c,d))&&e?(c=a[0]==e[0]||a[0]==e[2]?a[0]:null,d=a[1]==e[1]||a[1]==e[3]?a[1]:null,null!==c&&null!==d?this.a=Cu(b(a)):null!==c?this.a=Du(b([c,e[1]]),b([c,e[3]])):null!==d&&(this.a=Du(b([e[0],d]),b([e[2],d])))):(a=d.Xa(c),this.f([a[0],a[1],a[0],a[1]]),this.a=Cu(a));return!0}
function vu(a){this.a&&(a=a.coordinate,this.f(this.a(a)),Bu(this,a));return!0}function xu(){this.a=null;var a=this.D();a&&gb(a)||this.f(null);return!1}function yu(){var a=gl();return function(){return a.Polygon}}function zu(){var a=gl();return function(){return a.Point}}function Cu(a){return function(b){return Ia([a,b])}}function Du(a,b){return a[0]==b[0]?function(c){return Ia([a,[c[0],b[1]]])}:a[1]==b[1]?function(c){return Ia([a,[b[0],c[1]]])}:null}
function Au(a,b,c){function d(a,b){return gf(e,a)-gf(e,b)}var e=c.Xa(b),f=a.D();if(f){f=[[[f[0],f[1]],[f[0],f[3]]],[[f[0],f[3]],[f[2],f[3]]],[[f[2],f[3]],[f[2],f[1]]],[[f[2],f[1]],[f[0],f[1]]]];f.sort(d);var f=f[0],g=Ye(e,f),h=c.Ka(g);if(10>=ff(b,h))return b=c.Ka(f[0]),c=c.Ka(f[1]),b=ef(h,b),c=ef(h,c),a.C=10>=Math.sqrt(Math.min(b,c)),a.C&&(g=b>c?f[1]:f[0]),g}return null}function Bu(a,b){var c=a.G;c?c.U().pa(b):(c=new I(new E(b)),a.G=c,a.I.ka().zb(c))}
tu.prototype.setMap=function(a){this.u.setMap(a);this.I.setMap(a);Ag.prototype.setMap.call(this,a)};tu.prototype.D=function(){return this.j};tu.prototype.f=function(a){this.j=a?a:null;var b=this.o;b?a?b.Ta(Vf(a)):b.Ta(void 0):(this.o=b=a?new I(Vf(a)):new I({}),this.u.ka().zb(b));this.b(new Eu(this.j))};function Eu(a){Lc.call(this,Fu);this.b=a}u(Eu,Lc);var Fu="extentchanged";function Gu(a){Ag.call(this,{handleDownEvent:Hu,handleDragEvent:Iu,handleEvent:Ju,handleUpEvent:Ku});this.Gb=a.condition?a.condition:zg;this.Va=function(a){return vg(a)&&tg(a)};this.yb=a.deleteCondition?a.deleteCondition:this.Va;this.Ha=this.f=null;this.Ja=[0,0];this.C=this.I=!1;this.a=new Gj;this.fa=void 0!==a.pixelTolerance?a.pixelTolerance:10;this.o=this.na=!1;this.j=[];this.G=new S({source:new T({useSpatialIndex:!1,wrapX:!!a.wrapX}),style:a.style?a.style:Lu(),updateWhileAnimating:!0,updateWhileInteracting:!0});
this.T={Point:this.wn,LineString:this.li,LinearRing:this.li,Polygon:this.xn,MultiPoint:this.tn,MultiLineString:this.sn,MultiPolygon:this.vn,Circle:this.lq,GeometryCollection:this.rn};this.u=a.features;this.u.forEach(this.fg,this);z(this.u,"add",this.pn,this);z(this.u,"remove",this.qn,this);this.Z=null}u(Gu,Ag);k=Gu.prototype;k.fg=function(a){var b=a.U();b&&b.S()in this.T&&this.T[b.S()].call(this,a,b);(b=this.v)&&b.a&&this.c()&&Mu(this,this.Ja,b);z(a,"change",this.ki,this)};
function Nu(a,b){a.C||(a.C=!0,a.b(new Ou("modifystart",a.u,b)))}function Pu(a,b){Qu(a,b);a.f&&!a.u.fc()&&(a.G.ka().Db(a.f),a.f=null);Hc(b,"change",a.ki,a)}function Qu(a,b){var c=a.a,d=[];c.forEach(function(a){b===a.feature&&d.push(a)});for(var e=d.length-1;0<=e;--e)c.remove(d[e])}k.Ia=function(a){this.f&&!a&&(this.G.ka().Db(this.f),this.f=null);Ag.prototype.Ia.call(this,a)};k.setMap=function(a){this.G.setMap(a);Ag.prototype.setMap.call(this,a)};k.pn=function(a){this.fg(a.element)};
k.ki=function(a){this.o||(a=a.target,Pu(this,a),this.fg(a))};k.qn=function(a){Pu(this,a.element)};k.wn=function(a,b){var c=b.W(),c={feature:a,geometry:b,oa:[c,c]};this.a.Ea(b.D(),c)};k.tn=function(a,b){var c=b.W(),d,e,f;e=0;for(f=c.length;e<f;++e)d=c[e],d={feature:a,geometry:b,depth:[e],index:e,oa:[d,d]},this.a.Ea(b.D(),d)};k.li=function(a,b){var c=b.W(),d,e,f,g;d=0;for(e=c.length-1;d<e;++d)f=c.slice(d,d+2),g={feature:a,geometry:b,index:d,oa:f},this.a.Ea(Ia(f),g)};
k.sn=function(a,b){var c=b.W(),d,e,f,g,h,l,m;g=0;for(h=c.length;g<h;++g)for(d=c[g],e=0,f=d.length-1;e<f;++e)l=d.slice(e,e+2),m={feature:a,geometry:b,depth:[g],index:e,oa:l},this.a.Ea(Ia(l),m)};k.xn=function(a,b){var c=b.W(),d,e,f,g,h,l,m;g=0;for(h=c.length;g<h;++g)for(d=c[g],e=0,f=d.length-1;e<f;++e)l=d.slice(e,e+2),m={feature:a,geometry:b,depth:[g],index:e,oa:l},this.a.Ea(Ia(l),m)};
k.vn=function(a,b){var c=b.W(),d,e,f,g,h,l,m,n,p,q;l=0;for(m=c.length;l<m;++l)for(n=c[l],g=0,h=n.length;g<h;++g)for(d=n[g],e=0,f=d.length-1;e<f;++e)p=d.slice(e,e+2),q={feature:a,geometry:b,depth:[g,l],index:e,oa:p},this.a.Ea(Ia(p),q)};k.lq=function(a,b){var c=b.za(),d={feature:a,geometry:b,index:0,oa:[c,c]},e={feature:a,geometry:b,index:1,oa:[c,c]};d.Lf=e.Lf=[d,e];this.a.Ea(Xa(c),d);this.a.Ea(b.D(),e)};k.rn=function(a,b){var c,d=b.a;for(c=0;c<d.length;++c)this.T[d[c].S()].call(this,a,d[c])};
function Ru(a,b){var c=a.f;c?c.U().pa(b):(c=new I(new E(b)),a.f=c,a.G.ka().zb(c))}function Su(a,b){return a.index-b.index}
function Hu(a){if(!this.Gb(a))return!1;Mu(this,a.pixel,a.map);var b=a.map.Xa(a.pixel);this.j.length=0;this.C=!1;var c=this.f;if(c){var d=[],c=c.U().W(),e=Ia([c]),e=Jj(this.a,e),f={};e.sort(Su);for(var g=0,h=e.length;g<h;++g){var l=e[g],m=l.oa,n=w(l.feature),p=l.depth;p&&(n+="-"+p.join("-"));f[n]||(f[n]=Array(2));if("Circle"===l.geometry.S()&&1===l.index)m=Tu(b,l),af(m,c)&&!f[n][0]&&(this.j.push([l,0]),f[n][0]=l);else if(af(m[0],c)&&!f[n][0])this.j.push([l,0]),f[n][0]=l;else if(af(m[1],c)&&!f[n][1]){if("LineString"!==
l.geometry.S()&&"MultiLineString"!==l.geometry.S()||!f[n][0]||0!==f[n][0].index)this.j.push([l,1]),f[n][1]=l}else w(m)in this.Ha&&!f[n][0]&&!f[n][1]&&d.push([l,c])}d.length&&Nu(this,a);for(a=d.length-1;0<=a;--a)this.Xl.apply(this,d[a])}return!!this.f}
function Iu(a){this.I=!1;Nu(this,a);a=a.coordinate;for(var b=0,c=this.j.length;b<c;++b){for(var d=this.j[b],e=d[0],f=e.depth,g=e.geometry,h,l=e.oa,d=d[1];a.length<g.sa();)a.push(l[d][a.length]);switch(g.S()){case "Point":h=a;l[0]=l[1]=a;break;case "MultiPoint":h=g.W();h[e.index]=a;l[0]=l[1]=a;break;case "LineString":h=g.W();h[e.index+d]=a;l[d]=a;break;case "MultiLineString":h=g.W();h[f[0]][e.index+d]=a;l[d]=a;break;case "Polygon":h=g.W();h[f[0]][e.index+d]=a;l[d]=a;break;case "MultiPolygon":h=g.W();
h[f[1]][f[0]][e.index+d]=a;l[d]=a;break;case "Circle":l[0]=l[1]=a,0===e.index?(this.o=!0,g.lb(a)):(this.o=!0,g.Zc(ff(g.za(),a))),this.o=!1}h&&(e=g,f=h,this.o=!0,e.pa(f),this.o=!1)}Ru(this,a)}function Ku(a){for(var b,c,d=this.j.length-1;0<=d;--d)if(b=this.j[d][0],c=b.geometry,"Circle"===c.S()){var e=c.za(),f=b.Lf[0];b=b.Lf[1];f.oa[0]=f.oa[1]=e;b.oa[0]=b.oa[1]=e;Hj(this.a,Xa(e),f);Hj(this.a,c.D(),b)}else Hj(this.a,Ia(b.oa),b);this.C&&(this.b(new Ou("modifyend",this.u,a)),this.C=!1);return!1}
function Ju(a){if(!(a instanceof Kd))return!0;this.Z=a;var b;ag(a.map.$())[1]||"pointermove"!=a.type||this.A||(this.Ja=a.pixel,Mu(this,a.pixel,a.map));this.f&&this.yb(a)&&(b="singleclick"==a.type&&this.I?!0:this.cj());"singleclick"==a.type&&(this.I=!1);return Bg.call(this,a)&&!b}
function Mu(a,b,c){function d(a,b){return Uu(e,a)-Uu(e,b)}var e=c.Xa(b),f=Ma(Xa(e),c.$().Ra()*a.fa),f=Jj(a.a,f);if(0<f.length){f.sort(d);var g=f[0],h=g.oa,l=Tu(e,g),m=c.Ka(l),n=ff(b,m);if(n<=a.fa){b={};if("Circle"===g.geometry.S()&&1===g.index)a.na=!0,Ru(a,l);else for(n=c.Ka(h[0]),g=c.Ka(h[1]),c=ef(m,n),m=ef(m,g),n=Math.sqrt(Math.min(c,m)),a.na=n<=a.fa,a.na&&(l=c>m?h[1]:h[0]),Ru(a,l),m=1,c=f.length;m<c;++m)if(l=f[m].oa,af(h[0],l[0])&&af(h[1],l[1])||af(h[0],l[1])&&af(h[1],l[0]))b[w(l)]=!0;else break;
b[w(h)]=!0;a.Ha=b;return}}a.f&&(a.G.ka().Db(a.f),a.f=null)}function Uu(a,b){var c=b.geometry;if("Circle"===c.S()&&1===b.index){var d=ef(c.za(),a),c=Math.sqrt(d)-c.Yd();return c*c}return gf(a,b.oa)}function Tu(a,b){var c=b.geometry;return"Circle"===c.S()&&1===b.index?c.Ab(a):Ye(a,b.oa)}
k.Xl=function(a,b){for(var c=a.oa,d=a.feature,e=a.geometry,f=a.depth,g=a.index,h;b.length<e.sa();)b.push(0);switch(e.S()){case "MultiLineString":h=e.W();h[f[0]].splice(g+1,0,b);break;case "Polygon":h=e.W();h[f[0]].splice(g+1,0,b);break;case "MultiPolygon":h=e.W();h[f[1]][f[0]].splice(g+1,0,b);break;case "LineString":h=e.W();h.splice(g+1,0,b);break;default:return}this.o=!0;e.pa(h);this.o=!1;h=this.a;h.remove(a);Vu(this,e,g,f,1);var l={oa:[c[0],b],feature:d,geometry:e,depth:f,index:g};h.Ea(Ia(l.oa),
l);this.j.push([l,1]);c={oa:[b,c[1]],feature:d,geometry:e,depth:f,index:g+1};h.Ea(Ia(c.oa),c);this.j.push([c,0]);this.I=!0};
k.cj=function(){if(this.Z&&"pointerdrag"!=this.Z.type){var a=this.Z;Nu(this,a);var b=this.j,c={},d,e,f,g,h,l,m,n,p,q;for(h=b.length-1;0<=h;--h)g=b[h],p=g[0],q=w(p.feature),p.depth&&(q+="-"+p.depth.join("-")),q in c||(c[q]={}),0===g[1]?(c[q].right=p,c[q].index=p.index):1==g[1]&&(c[q].left=p,c[q].index=p.index+1);for(q in c){n=c[q].right;l=c[q].left;h=c[q].index;m=h-1;p=void 0!==l?l:n;0>m&&(m=0);g=p.geometry;e=f=g.W();d=!1;switch(g.S()){case "MultiLineString":2<f[p.depth[0]].length&&(f[p.depth[0]].splice(h,
1),d=!0);break;case "LineString":2<f.length&&(f.splice(h,1),d=!0);break;case "MultiPolygon":e=e[p.depth[1]];case "Polygon":e=e[p.depth[0]],4<e.length&&(h==e.length-1&&(h=0),e.splice(h,1),d=!0,0===h&&(e.pop(),e.push(e[0]),m=e.length-1))}d&&(d=g,this.o=!0,d.pa(f),this.o=!1,f=[],void 0!==l&&(this.a.remove(l),f.push(l.oa[0])),void 0!==n&&(this.a.remove(n),f.push(n.oa[1])),void 0!==l&&void 0!==n&&(l={depth:p.depth,feature:p.feature,geometry:p.geometry,index:m,oa:f},this.a.Ea(Ia(l.oa),l)),Vu(this,g,h,p.depth,
-1),this.f&&(this.G.ka().Db(this.f),this.f=null),b.length=0)}this.b(new Ou("modifyend",this.u,a));this.C=!1;return!0}return!1};function Vu(a,b,c,d,e){Lj(a.a,b.D(),function(a){a.geometry===b&&(void 0===d||void 0===a.depth||ja(a.depth,d))&&a.index>c&&(a.index+=e)})}function Lu(){var a=gl();return function(){return a.Point}}function Ou(a,b,c){Lc.call(this,a);this.features=b;this.mapBrowserEvent=c}u(Ou,Lc);function Wu(a){kg.call(this,{handleEvent:Xu});a=a?a:{};this.C=a.condition?a.condition:tg;this.A=a.addCondition?a.addCondition:kf;this.G=a.removeCondition?a.removeCondition:kf;this.I=a.toggleCondition?a.toggleCondition:wg;this.o=a.multi?a.multi:!1;this.l=a.filter?a.filter:jf;this.j=a.hitTolerance?a.hitTolerance:0;this.f=new S({source:new T({useSpatialIndex:!1,features:a.features,wrapX:a.wrapX}),style:a.style?a.style:Yu(),updateWhileAnimating:!0,updateWhileInteracting:!0});if(a.layers)if("function"===
typeof a.layers)a=a.layers;else{var b=a.layers;a=function(a){return fa(b,a)}}else a=jf;this.u=a;this.a={};a=this.f.ka().i;z(a,"add",this.yn,this);z(a,"remove",this.Cn,this)}u(Wu,kg);k=Wu.prototype;k.zn=function(){return this.f.ka().i};k.An=function(){return this.j};k.Bn=function(a){a=w(a);return this.a[a]};
function Xu(a){if(!this.C(a))return!0;var b=this.A(a),c=this.G(a),d=this.I(a),e=!b&&!c&&!d,f=a.map,g=this.f.ka().i,h=[],l=[];if(e){rb(this.a);f.we(a.pixel,function(a,b){if(this.l(a,b)){l.push(a);var c=w(a);this.a[c]=b;return!this.o}}.bind(this),{layerFilter:this.u,hitTolerance:this.j});for(e=g.fc()-1;0<=e;--e){var f=g.item(e),m=l.indexOf(f);-1<m?l.splice(m,1):(g.remove(f),h.push(f))}l.length&&g.ag(l)}else{f.we(a.pixel,function(a,e){if(this.l(a,e)){if(!b&&!d||fa(g.a,a))(c||d)&&fa(g.a,a)&&(h.push(a),
f=w(a),delete this.a[f]);else{l.push(a);var f=w(a);this.a[f]=e}return!this.o}}.bind(this),{layerFilter:this.u,hitTolerance:this.j});for(e=h.length-1;0<=e;--e)g.remove(h[e]);g.ag(l)}(0<l.length||0<h.length)&&this.b(new Zu($u,l,h,a));return sg(a)}k.Dn=function(a){this.j=a};k.setMap=function(a){var b=this.v,c=this.f.ka().i;b&&c.forEach(b.yj,b);kg.prototype.setMap.call(this,a);this.f.setMap(a);a&&c.forEach(a.tj,a)};
function Yu(){var a=gl();ha(a.Polygon,a.LineString);ha(a.GeometryCollection,a.LineString);return function(b){return b.U()?a[b.U().S()]:null}}k.yn=function(a){var b=this.v;b&&b.tj(a.element)};k.Cn=function(a){var b=this.v;b&&b.yj(a.element)};function Zu(a,b,c,d){Lc.call(this,a);this.selected=b;this.deselected=c;this.mapBrowserEvent=d}u(Zu,Lc);var $u="select";function av(a){Ag.call(this,{handleEvent:bv,handleDownEvent:jf,handleUpEvent:cv});a=a?a:{};this.o=a.source?a.source:null;this.fa=void 0!==a.vertex?a.vertex:!0;this.I=void 0!==a.edge?a.edge:!0;this.j=a.features?a.features:null;this.na=[];this.C={};this.Z={};this.u={};this.G=null;this.f=void 0!==a.pixelTolerance?a.pixelTolerance:10;this.Ja=dv.bind(this);this.a=new Gj;this.T={Point:this.Jn,LineString:this.oi,LinearRing:this.oi,Polygon:this.Kn,MultiPoint:this.Hn,MultiLineString:this.Gn,MultiPolygon:this.In,
GeometryCollection:this.Fn}}u(av,Ag);k=av.prototype;k.zb=function(a,b){var c=void 0!==b?b:!0,d=w(a),e=a.U();if(e){var f=this.T[e.S()];f&&(this.Z[d]=e.D(Ja()),f.call(this,a,e))}c&&(this.C[d]=z(a,"change",this.En,this))};k.wk=function(a){this.zb(a)};k.xk=function(a){this.Db(a)};k.mi=function(a){var b;a instanceof $t?b=a.feature:a instanceof Yc&&(b=a.element);this.zb(b)};k.ni=function(a){var b;a instanceof $t?b=a.feature:a instanceof Yc&&(b=a.element);this.Db(b)};
k.En=function(a){a=a.target;if(this.A){var b=w(a);b in this.u||(this.u[b]=a)}else this.zj(a)};k.Db=function(a,b){var c=void 0!==b?b:!0,d=w(a),e=this.Z[d];if(e){var f=this.a,g=[];Lj(f,e,function(b){a===b.feature&&g.push(b)});for(e=g.length-1;0<=e;--e)f.remove(g[e])}c&&(Bc(this.C[d]),delete this.C[d])};
k.setMap=function(a){var b=this.v,c=this.na,d;this.j?d=this.j:this.o&&(d=this.o.We());b&&(c.forEach(Bc),c.length=0,d.forEach(this.xk,this));Ag.prototype.setMap.call(this,a);a&&(this.j?c.push(z(this.j,"add",this.mi,this),z(this.j,"remove",this.ni,this)):this.o&&c.push(z(this.o,"addfeature",this.mi,this),z(this.o,"removefeature",this.ni,this)),d.forEach(this.wk,this))};k.bd=kf;k.zj=function(a){this.Db(a,!1);this.zb(a,!1)};
k.Fn=function(a,b){var c,d=b.a;for(c=0;c<d.length;++c)this.T[d[c].S()].call(this,a,d[c])};k.oi=function(a,b){var c=b.W(),d,e,f,g;d=0;for(e=c.length-1;d<e;++d)f=c.slice(d,d+2),g={feature:a,oa:f},this.a.Ea(Ia(f),g)};k.Gn=function(a,b){var c=b.W(),d,e,f,g,h,l,m;g=0;for(h=c.length;g<h;++g)for(d=c[g],e=0,f=d.length-1;e<f;++e)l=d.slice(e,e+2),m={feature:a,oa:l},this.a.Ea(Ia(l),m)};k.Hn=function(a,b){var c=b.W(),d,e,f;e=0;for(f=c.length;e<f;++e)d=c[e],d={feature:a,oa:[d,d]},this.a.Ea(b.D(),d)};
k.In=function(a,b){var c=b.W(),d,e,f,g,h,l,m,n,p,q;l=0;for(m=c.length;l<m;++l)for(n=c[l],g=0,h=n.length;g<h;++g)for(d=n[g],e=0,f=d.length-1;e<f;++e)p=d.slice(e,e+2),q={feature:a,oa:p},this.a.Ea(Ia(p),q)};k.Jn=function(a,b){var c=b.W(),c={feature:a,oa:[c,c]};this.a.Ea(b.D(),c)};k.Kn=function(a,b){var c=b.W(),d,e,f,g,h,l,m;g=0;for(h=c.length;g<h;++g)for(d=c[g],e=0,f=d.length-1;e<f;++e)l=d.slice(e,e+2),m={feature:a,oa:l},this.a.Ea(Ia(l),m)};
function bv(a){var b,c,d=a.pixel,e=a.coordinate;b=a.map;var f=b.Xa([d[0]-this.f,d[1]+this.f]);c=b.Xa([d[0]+this.f,d[1]-this.f]);var f=Ia([f,c]),g=Jj(this.a,f),h,f=!1,l=null;c=null;if(0<g.length){this.G=e;g.sort(this.Ja);g=g[0].oa;if(this.fa&&!this.I){if(e=b.Ka(g[0]),h=b.Ka(g[1]),e=ef(d,e),d=ef(d,h),h=Math.sqrt(Math.min(e,d)),h=h<=this.f)f=!0,l=e>d?g[1]:g[0],c=b.Ka(l)}else this.I&&(l=Ye(e,g),c=b.Ka(l),ff(d,c)<=this.f&&(f=!0,this.fa&&(e=b.Ka(g[0]),h=b.Ka(g[1]),e=ef(c,e),d=ef(c,h),h=Math.sqrt(Math.min(e,
d)),h=h<=this.f)))&&(l=e>d?g[1]:g[0],c=b.Ka(l));f&&(c=[Math.round(c[0]),Math.round(c[1])])}b=l;f&&(a.coordinate=b.slice(0,2),a.pixel=c);return Bg.call(this,a)}function cv(){var a=sb(this.u);a.length&&(a.forEach(this.zj,this),this.u={});return!1}function dv(a,b){return gf(this.G,a.oa)-gf(this.G,b.oa)};function ev(a){Ag.call(this,{handleDownEvent:fv,handleDragEvent:gv,handleMoveEvent:hv,handleUpEvent:iv});a=a?a:{};this.f=void 0;this.a=null;this.o=void 0!==a.features?a.features:null;var b;if(a.layers)if("function"===typeof a.layers)b=a.layers;else{var c=a.layers;b=function(a){return fa(c,a)}}else b=jf;this.G=b;this.u=a.hitTolerance?a.hitTolerance:0;this.j=null;z(this,Sc("active"),this.C,this)}u(ev,Ag);
function fv(a){this.j=jv(this,a.pixel,a.map);if(!this.a&&this.j){this.a=a.coordinate;hv.call(this,a);var b=this.o||new D([this.j]);this.b(new kv("translatestart",b,a.coordinate));return!0}return!1}function iv(a){if(this.a){this.a=null;hv.call(this,a);var b=this.o||new D([this.j]);this.b(new kv("translateend",b,a.coordinate));return!0}return!1}
function gv(a){if(this.a){a=a.coordinate;var b=a[0]-this.a[0],c=a[1]-this.a[1],d=this.o||new D([this.j]);d.forEach(function(a){var d=a.U();d.translate(b,c);a.Ta(d)});this.a=a;this.b(new kv("translating",d,a))}}function hv(a){var b=a.map.vc();jv(this,a.pixel,a.map)?(this.f=void 0!==this.f?this.f:b.style.cursor,b.style.cursor=this.a?"-webkit-grabbing":"-webkit-grab",b.style.cursor=this.a?"grabbing":"grab"):void 0!==this.f&&(b.style.cursor=this.f,this.f=void 0)}
function jv(a,b,c){return c.we(b,function(a){if(!this.o||fa(this.o.a,a))return a}.bind(a),{layerFilter:a.G,hitTolerance:a.u})}ev.prototype.I=function(){return this.u};ev.prototype.Z=function(a){this.u=a};ev.prototype.setMap=function(a){var b=this.v;Ag.prototype.setMap.call(this,a);lv(this,b)};ev.prototype.C=function(){lv(this,null)};function lv(a,b){var c=a.v,d=a.c();c&&d||void 0===a.f||(c||(c=b),c.vc().style.cursor=a.f,a.f=void 0)}
function kv(a,b,c){Lc.call(this,a);this.features=b;this.coordinate=c}u(kv,Lc);function U(a){a=a?a:{};var b=qb({},a);delete b.gradient;delete b.radius;delete b.blur;delete b.shadow;delete b.weight;S.call(this,b);this.j=null;this.T=void 0!==a.shadow?a.shadow:250;this.Z=void 0;this.I=null;z(this,Sc(mv),this.wl,this);this.kj(a.gradient?a.gradient:nv);this.ej(void 0!==a.blur?a.blur:15);this.Zc(void 0!==a.radius?a.radius:8);z(this,Sc(ov),this.Yf,this);z(this,Sc(pv),this.Yf,this);this.Yf();var c=a.weight?a.weight:"weight",d;"string"===typeof c?d=function(a){return a.get(c)}:d=c;this.f(function(a){a=
d(a);a=void 0!==a?xa(a,0,1):1;var b=255*a|0,c=this.I[b];c||(c=[new bl({image:new co({opacity:a,src:this.Z})})],this.I[b]=c);return c}.bind(this));this.set(It,null);z(this,"render",this.Nl,this)}u(U,S);var nv=["#00f","#0ff","#0f0","#ff0","#f00"];k=U.prototype;k.nh=function(){return this.get(ov)};k.uh=function(){return this.get(mv)};k.ri=function(){return this.get(pv)};
k.wl=function(){for(var a=this.uh(),b=hd(1,256),c=b.createLinearGradient(0,0,1,256),d=1/(a.length-1),e=0,f=a.length;e<f;++e)c.addColorStop(e*d,a[e]);b.fillStyle=c;b.fillRect(0,0,1,256);this.j=b.getImageData(0,0,1,256).data};k.Yf=function(){var a=this.ri(),b=this.nh(),c=a+b+1,d=2*c,d=hd(d,d);d.shadowOffsetX=d.shadowOffsetY=this.T;d.shadowBlur=b;d.shadowColor="#000";d.beginPath();b=c-this.T;d.arc(b,b,a,0,2*Math.PI,!0);d.fill();this.Z=d.canvas.toDataURL();this.I=Array(256);this.s()};
k.Nl=function(a){a=a.context;var b=a.canvas,b=a.getImageData(0,0,b.width,b.height),c=b.data,d,e,f;d=0;for(e=c.length;d<e;d+=4)if(f=4*c[d+3])c[d]=this.j[f],c[d+1]=this.j[f+1],c[d+2]=this.j[f+2];a.putImageData(b,0,0)};k.ej=function(a){this.set(ov,a)};k.kj=function(a){this.set(mv,a)};k.Zc=function(a){this.set(pv,a)};var ov="blur",mv="gradient",pv="radius";function qv(a){zt.call(this,a);this.u=yh();this.j=null}u(qv,zt);qv.prototype.O=function(a,b,c){Bt(this,"precompose",c,a,void 0);var d=this.Y();if(d){var e=b.extent,f=void 0!==e&&!Ua(e,a.extent)&&nb(e,a.extent);f&&At(c,a,e);var e=this.A(),g=c.globalAlpha;c.globalAlpha=b.opacity;c.drawImage(d,0,0,+d.width,+d.height,Math.round(e[4]),Math.round(e[5]),Math.round(d.width*e[0]),Math.round(d.height*e[3]));c.globalAlpha=g;f&&c.restore()}this.cf(c,a,b)};
qv.prototype.Ba=function(a,b,c,d,e){var f=this.a;return f.ka().Ba(a,b.viewState.resolution,b.viewState.rotation,c,b.skippedFeatureUids,function(a){return d.call(e,a,f)})};
qv.prototype.v=function(a,b,c,d){if(this.Y()){if(this.a.ka().Ba!==oa)return zt.prototype.v.apply(this,arguments);var e=Dh(this.u,a.slice());df(e,b.viewState.resolution/this.f);this.j||(this.j=hd(1,1));this.j.clearRect(0,0,1,1);this.j.drawImage(this.Y(),e[0],e[1],1,1,0,0,1,1);e=this.j.getImageData(0,0,1,1).data;if(0<e[3])return c.call(d,this.a,e)}};function rv(a){qv.call(this,a);this.N=null;this.c=yh()}u(rv,qv);rv.prototype.Y=function(){return this.N?this.N.Y():null};rv.prototype.A=function(){return this.c};
rv.prototype.ud=function(a,b){var c=a.pixelRatio,d=a.size,e=a.viewState,f=e.center,g=e.resolution,h=this.a.ka(),l=a.viewHints,m=a.extent;void 0!==b.extent&&(m=mb(m,b.extent));l[0]||l[1]||hb(m)||(e=h.Y(m,g,c,e.projection))&&tt(this,e)&&(this.N=e);if(this.N){var e=this.N,m=e.D(),n=e.resolution,l=e.a,p=c*n/(g*l),m=Hh(this.c,c*d[0]/2,c*d[1]/2,p,p,0,l*(m[0]-f[0])/n,l*(f[1]-m[3])/n);Hh(this.u,c*d[0]/2-m[4],c*d[1]/2-m[5],c/g,-c/g,0,-f[0],-f[1]);vt(a.attributions,e.i);wt(a,h);this.f=g*c/l}return!!this.N};function sv(a,b,c,d){var e=fc(c,b,a);c=Rb(b,d,c);b=b.uc();void 0!==b&&(c*=b);b=a.uc();void 0!==b&&(c/=b);a=Rb(a,c,e)/c;isFinite(a)&&0<a&&(c/=a);return c}function tv(a,b,c,d){a=c-a;b=d-b;var e=Math.sqrt(a*a+b*b);return[Math.round(c+a/e),Math.round(d+b/e)]}
function uv(a,b,c,d,e,f,g,h,l,m,n){var p=hd(Math.round(c*a),Math.round(c*b));if(!l.length)return p.canvas;p.scale(c,c);var q=Ja();l.forEach(function(a){ab(q,a.extent)});var r=hd(Math.round(c*ib(q)/d),Math.round(c*jb(q)/d)),v=c/d;l.forEach(function(a){r.drawImage(a.image,m,m,a.image.width-2*m,a.image.height-2*m,(a.extent[0]-q[0])*v,-(a.extent[3]-q[3])*v,ib(a.extent)*v,jb(a.extent)*v)});var x=fb(g);h.c.forEach(function(a){var b=a.source,e=a.target,g=b[1][0],h=b[1][1],l=b[2][0],m=b[2][1];a=(e[0][0]-
x[0])/f;var n=-(e[0][1]-x[1])/f,v=(e[1][0]-x[0])/f,y=-(e[1][1]-x[1])/f,Z=(e[2][0]-x[0])/f,Ta=-(e[2][1]-x[1])/f,e=b[0][0],b=b[0][1],g=g-e,h=h-b,l=l-e,m=m-b;a:{g=[[g,h,0,0,v-a],[l,m,0,0,Z-a],[0,0,g,h,y-n],[0,0,l,m,Ta-n]];h=g.length;for(l=0;l<h;l++){for(var m=l,Pb=Math.abs(g[l][l]),cc=l+1;cc<h;cc++){var $c=Math.abs(g[cc][l]);$c>Pb&&(Pb=$c,m=cc)}if(!Pb){g=null;break a}Pb=g[m];g[m]=g[l];g[l]=Pb;for(m=l+1;m<h;m++)for(Pb=-g[m][l]/g[l][l],cc=l;cc<h+1;cc++)g[m][cc]=l==cc?0:g[m][cc]+Pb*g[l][cc]}l=Array(h);
for(m=h-1;0<=m;m--)for(l[m]=g[m][h]/g[m][m],Pb=m-1;0<=Pb;Pb--)g[Pb][h]-=g[Pb][m]*l[m];g=l}g&&(p.save(),p.beginPath(),l=(a+v+Z)/3,m=(n+y+Ta)/3,h=tv(l,m,a,n),v=tv(l,m,v,y),Z=tv(l,m,Z,Ta),p.moveTo(v[0],v[1]),p.lineTo(h[0],h[1]),p.lineTo(Z[0],Z[1]),p.clip(),p.transform(g[0],g[2],g[1],g[3],a,n),p.translate(q[0]-e,q[3]-b),p.scale(d/c,-d/c),p.drawImage(r.canvas,0,0),p.restore())});n&&(p.save(),p.strokeStyle="black",p.lineWidth=1,h.c.forEach(function(a){var b=a.target;a=(b[0][0]-x[0])/f;var c=-(b[0][1]-x[1])/
f,d=(b[1][0]-x[0])/f,e=-(b[1][1]-x[1])/f,g=(b[2][0]-x[0])/f,b=-(b[2][1]-x[1])/f;p.beginPath();p.moveTo(d,e);p.lineTo(a,c);p.lineTo(g,b);p.closePath();p.stroke()}),p.restore());return p.canvas};function vv(a,b,c,d,e){this.g=a;this.i=b;var f={},g=dc(this.i,this.g);this.a=function(a){var b=a[0]+"/"+a[1];f[b]||(f[b]=g(a));return f[b]};this.f=d;this.u=e*e;this.c=[];this.l=!1;this.o=this.g.a&&!!d&&!!this.g.D()&&ib(d)==ib(this.g.D());this.b=this.g.D()?ib(this.g.D()):null;this.j=this.i.D()?ib(this.i.D()):null;a=fb(c);b=eb(c);d=db(c);c=cb(c);e=this.a(a);var h=this.a(b),l=this.a(d),m=this.a(c);wv(this,a,b,d,c,e,h,l,m,10);if(this.l){var n=Infinity;this.c.forEach(function(a){n=Math.min(n,a.source[0][0],
a.source[1][0],a.source[2][0])});this.c.forEach(function(a){if(Math.max(a.source[0][0],a.source[1][0],a.source[2][0])-n>this.b/2){var b=[[a.source[0][0],a.source[0][1]],[a.source[1][0],a.source[1][1]],[a.source[2][0],a.source[2][1]]];b[0][0]-n>this.b/2&&(b[0][0]-=this.b);b[1][0]-n>this.b/2&&(b[1][0]-=this.b);b[2][0]-n>this.b/2&&(b[2][0]-=this.b);Math.max(b[0][0],b[1][0],b[2][0])-Math.min(b[0][0],b[1][0],b[2][0])<this.b/2&&(a.source=b)}},this)}f={}}
function wv(a,b,c,d,e,f,g,h,l,m){var n=Ia([f,g,h,l]),p=a.b?ib(n)/a.b:null,q=a.b,r=a.g.a&&.5<p&&1>p,v=!1;if(0<m){if(a.i.g&&a.j)var x=Ia([b,c,d,e]),v=v|.25<ib(x)/a.j;!r&&a.g.g&&p&&(v|=.25<p)}if(v||!a.f||nb(n,a.f)){if(!(v||isFinite(f[0])&&isFinite(f[1])&&isFinite(g[0])&&isFinite(g[1])&&isFinite(h[0])&&isFinite(h[1])&&isFinite(l[0])&&isFinite(l[1])))if(0<m)v=!0;else return;if(0<m&&(v||(n=a.a([(b[0]+d[0])/2,(b[1]+d[1])/2]),q=r?(Da(f[0],q)+Da(h[0],q))/2-Da(n[0],q):(f[0]+h[0])/2-n[0],n=(f[1]+h[1])/2-n[1],
v=q*q+n*n>a.u),v)){Math.abs(b[0]-d[0])<=Math.abs(b[1]-d[1])?(r=[(c[0]+d[0])/2,(c[1]+d[1])/2],q=a.a(r),n=[(e[0]+b[0])/2,(e[1]+b[1])/2],p=a.a(n),wv(a,b,c,r,n,f,g,q,p,m-1),wv(a,n,r,d,e,p,q,h,l,m-1)):(r=[(b[0]+c[0])/2,(b[1]+c[1])/2],q=a.a(r),n=[(d[0]+e[0])/2,(d[1]+e[1])/2],p=a.a(n),wv(a,b,r,n,e,f,q,p,l,m-1),wv(a,r,c,d,n,q,g,h,p,m-1));return}if(r){if(!a.o)return;a.l=!0}a.c.push({source:[f,h,l],target:[b,d,e]});a.c.push({source:[f,g,h],target:[b,c,d]})}}
function xv(a){var b=Ja();a.c.forEach(function(a){a=a.source;La(b,a[0]);La(b,a[1]);La(b,a[2])});return b};function yv(a,b,c,d,e,f){this.u=b;this.o=a.D();var g=b.D(),h=g?mb(c,g):c,g=sv(a,b,kb(h),d);this.j=new vv(a,b,h,this.o,.5*g);this.c=d;this.g=c;a=xv(this.j);this.l=(this.Eb=f(a,g,e))?this.Eb.a:1;this.de=this.f=null;e=2;f=[];this.Eb&&(e=0,f=this.Eb.i);Fs.call(this,c,d,this.l,e,f)}u(yv,Fs);yv.prototype.ra=function(){1==this.state&&(Bc(this.de),this.de=null);Fs.prototype.ra.call(this)};yv.prototype.Y=function(){return this.f};
yv.prototype.ce=function(){var a=this.Eb.V();2==a&&(this.f=uv(ib(this.g)/this.c,jb(this.g)/this.c,this.l,this.Eb.resolution,0,this.c,this.g,this.j,[{extent:this.Eb.D(),image:this.Eb.Y()}],0));this.state=a;this.s()};yv.prototype.load=function(){if(0==this.state){this.state=1;this.s();var a=this.Eb.V();2==a||3==a?this.ce():(this.de=z(this.Eb,"change",function(){var a=this.Eb.V();if(2==a||3==a)Bc(this.de),this.de=null,this.ce()},this),this.Eb.load())}};function zv(a){Tt.call(this,{attributions:a.attributions,extent:a.extent,logo:a.logo,projection:a.projection,state:a.state});this.v=void 0!==a.resolutions?a.resolutions:null;this.a=null;this.ea=0}u(zv,Tt);function Av(a,b){a.v&&(b=a.v[ga(a.v,b,0)]);return b}
zv.prototype.Y=function(a,b,c,d){var e=this.c;if(e&&d&&!bc(e,d)){if(this.a){if(this.ea==this.g&&bc(this.a.u,d)&&this.a.resolution==b&&this.a.a==c&&$a(this.a.D(),a))return this.a;Kc(this.a);this.a=null}this.a=new yv(e,d,a,b,c,function(a,b,c){return this.Lc(a,b,c,e)}.bind(this));this.ea=this.g;return this.a}e&&(d=e);return this.Lc(a,b,c,d)};zv.prototype.l=function(a){a=a.target;switch(a.V()){case 1:this.b(new Bv(Cv,a));break;case 2:this.b(new Bv(Dv,a));break;case 3:this.b(new Bv(Ev,a))}};
function Fv(a,b){a.Y().src=b}function Bv(a,b){Lc.call(this,a);this.image=b}u(Bv,Lc);var Cv="imageloadstart",Dv="imageloadend",Ev="imageloaderror";function Gv(a){zv.call(this,{attributions:a.attributions,logo:a.logo,projection:a.projection,resolutions:a.resolutions,state:a.state});this.fa=a.canvasFunction;this.I=null;this.T=0;this.na=void 0!==a.ratio?a.ratio:1.5}u(Gv,zv);Gv.prototype.Lc=function(a,b,c,d){b=Av(this,b);var e=this.I;if(e&&this.T==this.g&&e.resolution==b&&e.a==c&&Ua(e.D(),a))return e;a=a.slice();ob(a,this.na);(d=this.fa(a,b,c,[ib(a)/b*c,jb(a)/b*c],d))&&(e=new Hs(a,b,c,this.j,d));this.I=e;this.T=this.g;return e};function Hv(a){this.i=a.source;this.Va=yh();this.f=hd();this.o=[0,0];this.Ha=void 0==a.renderBuffer?100:a.renderBuffer;this.A=null;Gv.call(this,{attributions:a.attributions,canvasFunction:this.pk.bind(this),logo:a.logo,projection:a.projection,ratio:a.ratio,resolutions:a.resolutions,state:this.i.V()});this.C=null;this.u=void 0;this.Bi(a.style);z(this.i,"change",this.ho,this)}u(Hv,Gv);k=Hv.prototype;
k.pk=function(a,b,c,d,e){var f=new it(.5*b/c,a,b,this.i.Ha,this.Ha);this.i.Xd(a,b,e);var g=!1;this.i.bc(a,function(a){var d;if(!(d=g)){var e;(d=a.Rc())?e=d.call(a,b):this.u&&(e=this.u(a,b));if(e){var h,p=!1;Array.isArray(e)||(e=[e]);d=0;for(h=e.length;d<h;++d)p=Ft(f,a,e[d],Et(b,c),this.fo,this)||p;d=p}else d=!1}g=d},this);mt(f);if(g)return null;this.o[0]!=d[0]||this.o[1]!=d[1]?(this.f.canvas.width=d[0],this.f.canvas.height=d[1],this.o[0]=d[0],this.o[1]=d[1]):this.f.clearRect(0,0,d[0],d[1]);a=Iv(this,
kb(a),b,c,d);f.i(this.f,c,a,0,{});this.A=f;return this.f.canvas};k.Ba=function(a,b,c,d,e,f){if(this.A){var g={};return this.A.Ba(a,b,0,d,e,function(a){var b=w(a).toString();if(!(b in g))return g[b]=!0,f(a)})}};k.bo=function(){return this.i};k.co=function(){return this.C};k.eo=function(){return this.u};function Iv(a,b,c,d,e){c=d/c;return Hh(a.Va,e[0]/2,e[1]/2,c,-c,0,-b[0],-b[1])}k.fo=function(){this.s()};k.ho=function(){Vt(this,this.i.V())};
k.Bi=function(a){this.C=void 0!==a?a:fl;this.u=a?dl(this.C):void 0;this.s()};function Jv(a,b){Ot.call(this,a,b);this.l=this.i=this.N=null}u(Jv,Ot);function Kv(a,b){var c=b.Y();return Qi(a.c.g,c)}Jv.prototype.Ba=function(a,b,c,d,e){var f=this.a;return f.ka().Ba(a,b.viewState.resolution,b.viewState.rotation,c,b.skippedFeatureUids,function(a){return d.call(e,a,f)})};
Jv.prototype.ig=function(a,b){var c=this.c.g,d=a.pixelRatio,e=a.viewState,f=e.center,g=e.resolution,h=e.rotation,l=this.N,m=this.Fb,n=this.a.ka(),p=a.viewHints,q=a.extent;void 0!==b.extent&&(q=mb(q,b.extent));p[0]||p[1]||hb(q)||(e=n.Y(q,g,d,e.projection))&&tt(this,e)&&(l=e,m=Kv(this,e),this.Fb&&a.postRenderFunctions.push(function(a,b){a.isContextLost()||a.deleteTexture(b)}.bind(null,c,this.Fb)));l&&(c=this.c.i.j,Lv(this,c.width,c.height,d,f,g,h,l.D()),this.l=null,d=this.u,zh(d),Fh(d,1,-1),Gh(d,0,
-1),this.N=l,this.Fb=m,vt(a.attributions,l.i),wt(a,n));return!!l};function Lv(a,b,c,d,e,f,g,h){b*=f;c*=f;a=a.O;zh(a);Fh(a,2*d/b,2*d/c);Eh(a,-g);Gh(a,h[0]-e[0],h[1]-e[1]);Fh(a,(h[2]-h[0])/2,(h[3]-h[1])/2);Gh(a,1,1)}Jv.prototype.Te=function(a,b){return void 0!==this.Ba(a,b,0,jf,this)};
Jv.prototype.gg=function(a,b,c,d){if(this.N&&this.N.Y())if(this.a.ka()instanceof Hv){var e=Dh(b.pixelToCoordinateTransform,a.slice());if(this.Ba(e,b,0,jf,this))return c.call(d,this.a,null)}else{e=[this.N.Y().width,this.N.Y().height];if(!this.l){var f=b.size;b=yh();Gh(b,-1,-1);Fh(b,2/f[0],2/f[1]);Gh(b,0,f[1]);Fh(b,1,-1);var f=Ih(this.O.slice()),g=yh();Gh(g,0,e[1]);Fh(g,1,-1);Fh(g,e[0]/2,e[1]/2);Gh(g,1,1);Bh(g,f);Bh(g,b);this.l=g}a=Dh(this.l,a.slice());if(!(0>a[0]||a[0]>e[0]||0>a[1]||a[1]>e[1])&&(this.i||
(this.i=hd(1,1)),this.i.clearRect(0,0,1,1),this.i.drawImage(this.N.Y(),a[0],a[1],1,1,0,0,1,1),e=this.i.getImageData(0,0,1,1).data,0<e[3]))return c.call(d,this.a,e)}};function Mv(a){th.call(this,a?a:{})}u(Mv,th);Mv.prototype.Gd=function(a){var b=null,c=a.S();"canvas"===c?b=new rv(this):"webgl"===c&&(b=new Jv(a,this));return b};function Nv(a){qv.call(this,a);this.c=null===this.c?null:hd();this.l=null;this.i=[];this.o=Ja();this.Ja=new ta(0,0,0,0);this.C=yh();this.T=0}u(Nv,qv);function Ov(a,b){var c=b.V(),d=a.a.Wd();return 2==c||4==c||3==c&&!d}
Nv.prototype.ud=function(a,b){var c=a.pixelRatio,d=a.size,e=a.viewState,f=e.projection,g=e.resolution,e=e.center,h=this.a,l=h.ka(),m=l.g,n=l.Jb(f),p=n.Qc(g,this.T),q=n.La(p),r=Math.round(g/q)||1,v=a.extent;void 0!==b.extent&&(v=mb(v,b.extent));if(hb(v))return!1;var x=qc(n,v,q),y;y=n.Uc(p);var A=n.La(p),B=Ha(n.eb(p),n.j);y=Wa(y[0]+x.da*B[0]*A,y[1]+x.ga*B[1]*A,y[0]+(x.ba+1)*B[0]*A,y[1]+(x.ja+1)*B[1]*A,void 0);A=l.pb(c);B={};B[p]={};var aa=this.Jf(l,f,B),Ra=this.o,ra=this.Ja,Ka=!1,C,Na,wb;for(Na=x.da;Na<=
x.ba;++Na)for(wb=x.ga;wb<=x.ja;++wb)C=l.Pc(p,Na,wb,c,f),Ov(this,C)||(C=Js(C)),Ov(this,C)?2==C.V()&&(B[p][C.Ga.toString()]=C,Ka||-1!=this.i.indexOf(C)||(Ka=!0)):oc(n,C.Ga,aa,ra,Ra)||(C=pc(n,C.Ga,ra,Ra))&&aa(p+1,C);Na=a.viewHints;if(!(this.f&&16<Date.now()-a.time&&(Na[0]||Na[1])||!Ka&&this.l&&Ua(this.l,v)&&this.kf==m)||r!=this.I){if(Na=this.c)wb=l.Vd(p,c,f),C=Math.round((x.ba-x.da+1)*wb[0]/r),wb=Math.round((x.ja-x.ga+1)*wb[1]/r),Ka=Na.canvas,Ka.width!=C||Ka.height!=wb?(this.I=r,Ka.width=C,Ka.height=
wb):(Na.clearRect(0,0,C,wb),r=this.I);this.i.length=0;Ka=Object.keys(B).map(Number);Ka.sort(ea);var Z,Ta,Pb,cc,$c,re,ra=0;for(Ta=Ka.length;ra<Ta;++ra){Na=Ka[ra];aa=l.Vd(Na,c,f);C=n.La(Na);Z=C/q;Pb=A*l.Rf(f);cc=B[Na];for(var Jd in cc)C=cc[Jd],wb=n.Ua(C.Ga,Ra),Na=(wb[0]-y[0])/q*A/r,wb=(y[3]-wb[3])/q*A/r,$c=aa[0]*Z/r,re=aa[1]*Z/r,this.Kf(C,a,b,Na,wb,$c,re,Pb),this.i.push(C)}this.kf=m;this.f=q*c/A*r;this.l=y}Jd=this.f/g;Jd=Hh(this.C,c*d[0]/2,c*d[1]/2,Jd,Jd,0,(this.l[0]-e[0])/this.f*c,(e[1]-this.l[3])/
this.f*c);Hh(this.u,c*d[0]/2-Jd[4],c*d[1]/2-Jd[5],c/g,-c/g,0,-e[0],-e[1]);xt(a.usedTiles,l,p,x);yt(a,l,n,c,f,v,p,h.Sd());ut(a,l);wt(a,l);return 0<this.i.length};Nv.prototype.Kf=function(a,b,c,d,e,f,g,h){this.a.ka().Uf(b.viewState.projection)||this.c.clearRect(d,e,f,g);(a=a.Y())&&this.c.drawImage(a,h,h,a.width-2*h,a.height-2*h,d,e,f,g)};Nv.prototype.Y=function(){var a=this.c;return a?a.canvas:null};Nv.prototype.A=function(){return this.C};function Pv(){this.b="precision mediump float;varying vec2 a;uniform sampler2D e;void main(void){gl_FragColor=texture2D(e,a);}"}u(Pv,ji);var Qv=new Pv;function Rv(){this.b="varying vec2 a;attribute vec2 b;attribute vec2 c;uniform vec4 d;void main(void){gl_Position=vec4(b*d.xy+d.zw,0.,1.);a=c;}"}u(Rv,ki);var Sv=new Rv;function Tv(a,b){this.g=a.getUniformLocation(b,"e");this.c=a.getUniformLocation(b,"d");this.b=a.getAttribLocation(b,"b");this.a=a.getAttribLocation(b,"c")};function Uv(a,b){Ot.call(this,a,b);this.I=Qv;this.fa=Sv;this.i=null;this.G=new Ai([0,0,0,1,1,0,1,1,0,1,0,0,1,1,1,0]);this.A=this.l=null;this.o=-1;this.Z=[0,0]}u(Uv,Ot);k=Uv.prototype;k.ra=function(){Di(this.c.i,this.G);Ot.prototype.ra.call(this)};k.Jf=function(a,b,c){var d=this.c;return function(e,f){return rt(a,b,e,f,function(a){var b=d.a.b.hasOwnProperty(a.hb());b&&(c[e]||(c[e]={}),c[e][a.Ga.toString()]=a);return b})}};k.hg=function(){Ot.prototype.hg.call(this);this.i=null};
k.ig=function(a,b,c){var d=this.c,e=c.b,f=a.viewState,g=f.projection,h=this.a,l=h.ka(),m=l.Jb(g),n=m.Qc(f.resolution),p=m.La(n),q=l.Vd(n,a.pixelRatio,g),r=q[0]/Ha(m.eb(n),this.Z)[0],v=p/r,x=l.pb(r)*l.Rf(g),y=f.center,A=a.extent,B=qc(m,A,p);if(this.l&&va(this.l,B)&&this.o==l.g)v=this.A;else{var aa=[B.ba-B.da+1,B.ja-B.ga+1],Ra=za(Math.max(aa[0]*q[0],aa[1]*q[1])),aa=v*Ra,ra=m.Uc(n),Ka=ra[0]+B.da*q[0]*v,v=ra[1]+B.ga*q[1]*v,v=[Ka,v,Ka+aa,v+aa];Pt(this,a,Ra);e.viewport(0,0,Ra,Ra);e.clearColor(0,0,0,0);
e.clear(16384);e.disable(3042);Ra=Ei(c,this.I,this.fa);c.Vc(Ra);this.i||(this.i=new Tv(e,Ra));ti(c,34962,this.G);e.enableVertexAttribArray(this.i.b);e.vertexAttribPointer(this.i.b,2,5126,!1,16,0);e.enableVertexAttribArray(this.i.a);e.vertexAttribPointer(this.i.a,2,5126,!1,16,8);e.uniform1i(this.i.g,0);c={};c[n]={};var C=this.Jf(l,g,c),Na=h.Wd(),Ra=!0,Ka=Ja(),wb=new ta(0,0,0,0),Z,Ta,Pb;for(Ta=B.da;Ta<=B.ba;++Ta)for(Pb=B.ga;Pb<=B.ja;++Pb){ra=l.Pc(n,Ta,Pb,r,g);if(void 0!==b.extent&&(Z=m.Ua(ra.Ga,Ka),
!nb(Z,b.extent)))continue;Z=ra.V();(Z=2==Z||4==Z||3==Z&&!Na)||(ra=Js(ra));Z=ra.V();if(2==Z){if(d.a.b.hasOwnProperty(ra.hb())){c[n][ra.Ga.toString()]=ra;continue}}else if(4==Z||3==Z&&!Na)continue;Ra=!1;Z=oc(m,ra.Ga,C,wb,Ka);Z||(ra=pc(m,ra.Ga,wb,Ka))&&C(n+1,ra)}b=Object.keys(c).map(Number);b.sort(ea);for(var C=new Float32Array(4),cc,Na=0,wb=b.length;Na<wb;++Na)for(cc in Ta=c[b[Na]],Ta)ra=Ta[cc],Z=m.Ua(ra.Ga,Ka),C[0]=2*(Z[2]-Z[0])/aa,C[1]=2*(Z[3]-Z[1])/aa,C[2]=2*(Z[0]-v[0])/aa-1,C[3]=2*(Z[1]-v[1])/aa-
1,e.uniform4fv(this.i.c,C),nk(d,ra,q,x*r),e.drawArrays(5,0,4);Ra?(this.l=B,this.A=v,this.o=l.g):(this.A=this.l=null,this.o=-1,a.animate=!0)}xt(a.usedTiles,l,n,B);var $c=d.j;yt(a,l,m,r,g,A,n,h.Sd(),function(a){2!=a.V()||d.a.b.hasOwnProperty(a.hb())||a.hb()in $c.a||$c.i([a,sc(m,a.Ga),m.La(a.Ga[0]),q,x*r])},this);ut(a,l);wt(a,l);e=this.u;zh(e);Gh(e,(Math.round(y[0]/p)*p-v[0])/(v[2]-v[0]),(Math.round(y[1]/p)*p-v[1])/(v[3]-v[1]));f.rotation&&Eh(e,f.rotation);Fh(e,a.size[0]*f.resolution/(v[2]-v[0]),a.size[1]*
f.resolution/(v[3]-v[1]));Gh(e,-.5,-.5);return!0};k.gg=function(a,b,c,d){if(this.f){a=Dh(this.u,[a[0]/b.size[0],(b.size[1]-a[1])/b.size[1]].slice());a=[a[0]*this.j,a[1]*this.j];b=this.c.i.b;b.bindFramebuffer(b.FRAMEBUFFER,this.f);var e=new Uint8Array(4);b.readPixels(a[0],a[1],1,1,b.RGBA,b.UNSIGNED_BYTE,e);if(0<e[3])return c.call(d,this.a,e)}};function Vv(a){a=a?a:{};var b=qb({},a);delete b.preload;delete b.useInterimTilesOnError;th.call(this,b);this.si(void 0!==a.preload?a.preload:0);this.ti(void 0!==a.useInterimTilesOnError?a.useInterimTilesOnError:!0)}u(Vv,th);k=Vv.prototype;k.Gd=function(a){var b=null,c=a.S();"canvas"===c?b=new Nv(this):"webgl"===c&&(b=new Uv(a,this));return b};k.Sd=function(){return this.get("preload")};k.si=function(a){this.set("preload",a)};k.Wd=function(){return this.get("useInterimTilesOnError")};
k.ti=function(a){this.set("useInterimTilesOnError",a)};function Wv(a){this.c=null;Nv.call(this,a);this.G=!1;this.Z=yh();this.T="vector"==a.u?1:0}u(Wv,Nv);var Xv={image:gi,hybrid:["Polygon","LineString"]},Yv={hybrid:["Image","Text"],vector:gi};k=Wv.prototype;k.ud=function(a,b){var c=this.a,d=c.g;this.na!=d&&(this.i.length=0,c=c.u,this.c||"vector"==c||(this.c=hd()),this.c&&"vector"==c&&(this.c=null));this.na=d;return Nv.prototype.ud.apply(this,arguments)};
function Zv(a,b,c){function d(a){var b,c=a.Rc();c?b=c.call(a,r):(c=e.i)&&(b=c(a,r));if(b){Array.isArray(b)||(b=[b]);var c=B,d=A;if(b){var f=!1;if(Array.isArray(b))for(var g=0,h=b.length;g<h;++g)f=Ft(d,a,b[g],c,this.yi,this)||f;else f=Ft(d,a,b,c,this.yi,this)||f;a=f}else a=!1;this.G=this.G||a;l.Od=l.Od||a}}var e=a.a,f=c.pixelRatio;c=c.viewState.projection;var g=e.g,h=e.get(It)||null,l=b.g;if(l.Od||l.kf!=g||l.Eg!=h){l.zd=null;l.Od=!1;var m=e.ka(),n=m.tileGrid,p=b.Ga,q=b.j,r=n.La(p[0]),v,x,y;"tile-pixels"==
q.Kb()?(v=y=m.pb(),n=Ha(n.eb(p[0])),v=[0,0,n[0]*v,n[1]*v]):(y=r,v=n.Ua(p),bc(c,q)||(x=!0,b.dg(c)));l.Od=!1;var A=new it(0,v,y,m.f,e.c),B=Et(y,f);b=b.f;h&&h!==l.Eg&&b.sort(h);m=0;for(y=b.length;m<y;++m)f=b[m],x&&f.U().tb(q,c),d.call(a,f);mt(A);l.kf=g;l.Eg=h;l.zd=A;l.resolution=NaN}}
k.Kf=function(a,b,c,d,e,f,g,h){var l=a;Zv(this,l,b);if(this.c){var m=l,n=b,p=this.a,l=m.g,q=p.g,r=Xv[p.u];if(r&&l.Fg!==q){l.Fg=q;var v=m.Ga,x=m.Ga[0],q=n.pixelRatio,y=p.ka(),A=y.tileGrid,B=y.pb(),p=zh(this.Z);"tile-pixels"==m.j.Kb()?(v=q/B,Fh(p,v,v)):(B=q/A.La(x),v=A.Ua(v,this.o),Fh(p,B,-B),Gh(p,-v[0],-v[3]));m.c||(m.c=hd());m=m.c;n=y.Vd(x,q,n.viewState.projection);m.canvas.width=n[0];m.canvas.height=n[1];l.zd.i(m,q,p,0,{},r)}Nv.prototype.Kf.apply(this,arguments)}};
k.Ba=function(a,b,c,d,e){var f=b.viewState.resolution;b=b.viewState.rotation;c=void 0==c?0:c;var g=this.a,h={},l=this.i,m=g.ka(),n=m.tileGrid,p,q,r,v,x,y;r=0;for(v=l.length;r<v;++r)y=l[r],q=y.Ga,x=m.tileGrid.Ua(q,this.o),Qa(Ma(x,c*f),a)&&("tile-pixels"===y.j.Kb()?(x=fb(x),f=m.pb(),q=n.La(q[0])/f,q=[(a[0]-x[0])/q,(x[1]-a[1])/q]):q=a,y=y.g.zd,p=p||y.Ba(q,f,b,c,{},function(a){var b=w(a).toString();if(!(b in h))return h[b]=!0,d.call(e,a,g)}));return p};k.yi=function(){st(this)};
k.cf=function(a,b,c){var d=Yv[this.a.u];if(d)for(var e=b.pixelRatio,f=b.viewState.rotation,g=b.size,h=Math.round(e*g[0]/2),g=Math.round(e*g[1]/2),l=this.i,m=[],n=[],p=l.length-1;0<=p;--p){var q=l[p],r;var v=q;r=b;if("tile-pixels"==v.j.Kb()){var x=this.a.ka(),y=x.tileGrid,A=v.Ga,x=y.La(A[0])/x.pb(),v=r.viewState,B=r.pixelRatio,aa=v.resolution/B,A=y.Ua(A,this.o),y=v.center,A=fb(A);r=r.size;r=Hh(this.Z,Math.round(B*r[0]/2),Math.round(B*r[1]/2),x/aa,x/aa,v.rotation,(A[0]-y[0])/x,(y[1]-A[1])/x)}else r=
Ct(this,r,0);x=ot(q.g.zd,r);v=q.Ga[0];a.save();a.globalAlpha=c.opacity;Sh(a,-f,h,g);B=0;for(aa=m.length;B<aa;++B)y=m[B],v<n[B]&&(a.beginPath(),a.moveTo(x[0],x[1]),a.lineTo(x[2],x[3]),a.lineTo(x[4],x[5]),a.lineTo(x[6],x[7]),a.moveTo(y[6],y[7]),a.lineTo(y[4],y[5]),a.lineTo(y[2],y[3]),a.lineTo(y[0],y[1]),a.clip());q.g.zd.i(a,e,r,f,{},d);a.restore();m.push(x);n.push(v)}Nv.prototype.cf.apply(this,arguments)};function V(a){a=a?a:{};var b=qb({},a);delete b.preload;delete b.useInterimTilesOnError;S.call(this,b);this.ui(a.preload?a.preload:0);this.vi(a.useInterimTilesOnError?a.useInterimTilesOnError:!0);sa(void 0==a.renderMode||"image"==a.renderMode||"hybrid"==a.renderMode||"vector"==a.renderMode,28);this.u=a.renderMode||"hybrid"}u(V,S);k=V.prototype;k.Gd=function(a){var b=null;"canvas"===a.S()&&(b=new Wv(this));return b};k.Sd=function(){return this.get("preload")};k.Wd=function(){return this.get("useInterimTilesOnError")};
k.ui=function(a){this.set("preload",a)};k.vi=function(a){this.set("useInterimTilesOnError",a)};function $v(a,b,c,d){function e(){delete window[g];f.parentNode.removeChild(f)}var f=document.createElement("script"),g="olc_"+w(b);f.async=!0;f.src=a+(-1==a.indexOf("?")?"?":"&")+(d||"callback")+"="+g;var h=setTimeout(function(){e();c&&c()},1E4);window[g]=function(a){clearTimeout(h);e();b(a)};document.getElementsByTagName("head")[0].appendChild(f)};function aw(a,b,c,d,e,f,g,h,l,m,n){Is.call(this,e,0);this.C=void 0!==n?n:!1;this.A=g;this.O=h;this.v=null;this.c=b;this.l=d;this.o=f?f:e;this.g=[];this.Ad=null;this.f=0;f=d.Ua(this.o);h=this.l.D();e=this.c.D();f=h?mb(f,h):f;if(gb(f))if((h=a.D())&&(e?e=mb(e,h):e=h),d=sv(a,c,kb(f),d.La(this.o[0])),!isFinite(d)||0>=d)this.state=4;else if(this.u=new vv(a,c,f,e,d*(void 0!==m?m:.5)),this.u.c.length)if(this.f=b.Qc(d),c=xv(this.u),e&&(a.a?(c[1]=xa(c[1],e[1],e[3]),c[3]=xa(c[3],e[1],e[3])):c=mb(c,e)),gb(c)){a=
nc(b,c,this.f);for(b=a.da;b<=a.ba;b++)for(c=a.ga;c<=a.ja;c++)(m=l(this.f,b,c,g))&&this.g.push(m);this.g.length||(this.state=4)}else this.state=4;else this.state=4;else this.state=4}u(aw,Is);aw.prototype.ra=function(){1==this.state&&(this.Ad.forEach(Bc),this.Ad=null);Is.prototype.ra.call(this)};aw.prototype.Y=function(){return this.v};
aw.prototype.ce=function(){var a=[];this.g.forEach(function(b){b&&2==b.V()&&a.push({extent:this.c.Ua(b.Ga),image:b.Y()})},this);this.g.length=0;if(a.length){var b=this.o[0],c=this.l.eb(b),d="number"===typeof c?c:c[0],c="number"===typeof c?c:c[1],b=this.l.La(b),e=this.c.La(this.f),f=this.l.Ua(this.o);this.v=uv(d,c,this.A,e,this.c.D(),b,f,this.u,a,this.O,this.C);this.state=2}else this.state=3;this.s()};
aw.prototype.load=function(){if(0==this.state){this.state=1;this.s();var a=0;this.Ad=[];this.g.forEach(function(b){var c=b.V();if(0==c||1==c){a++;var d;d=z(b,"change",function(){var c=b.V();if(2==c||3==c||4==c)Bc(d),a--,a||(this.Ad.forEach(Bc),this.Ad=null,this.ce())},this);this.Ad.push(d)}},this);this.g.forEach(function(a){0==a.V()&&a.load()});a||setTimeout(this.ce.bind(this),0)}};function bw(a,b){var c=/\{z\}/g,d=/\{x\}/g,e=/\{y\}/g,f=/\{-y\}/g;return function(g){if(g)return a.replace(c,g[0].toString()).replace(d,g[1].toString()).replace(e,function(){return(-g[2]-1).toString()}).replace(f,function(){var a=b.a?b.a[g[0]]:null;sa(a,55);return(a.ja-a.ga+1+g[2]).toString()})}}function cw(a,b){for(var c=a.length,d=Array(c),e=0;e<c;++e)d[e]=bw(a[e],b);return dw(d)}function dw(a){return 1===a.length?a[0]:function(b,c,d){if(b)return a[Da((b[1]<<b[0])+b[2],a.length)](b,c,d)}}
function ew(){}function fw(a){var b=[],c=/\{([a-z])-([a-z])\}/.exec(a);if(c){var d=c[2].charCodeAt(0),e;for(e=c[1].charCodeAt(0);e<=d;++e)b.push(a.replace(c[0],String.fromCharCode(e)));return b}if(c=c=/\{(\d+)-(\d+)\}/.exec(a)){d=parseInt(c[2],10);for(e=parseInt(c[1],10);e<=d;e++)b.push(a.replace(c[0],e.toString()));return b}b.push(a);return b};function gw(a){lk.call(this);this.highWaterMark=void 0!==a?a:2048}u(gw,lk);function hw(a){return a.c>a.highWaterMark}gw.prototype.ld=function(a){for(var b,c;hw(this);){b=this.a.cd;c=b.Ga[0].toString();var d;if(d=c in a)b=b.Ga,d=ua(a[c],b[1],b[2]);if(d)break;else Kc(this.pop())}};function iw(a){Tt.call(this,{attributions:a.attributions,extent:a.extent,logo:a.logo,projection:a.projection,state:a.state,wrapX:a.wrapX});this.na=void 0!==a.opaque?a.opaque:!1;this.Va=void 0!==a.tilePixelRatio?a.tilePixelRatio:1;this.tileGrid=void 0!==a.tileGrid?a.tileGrid:null;this.a=new gw(a.cacheSize);this.l=[0,0];this.wc=""}u(iw,Tt);k=iw.prototype;k.Ei=function(){return hw(this.a)};k.ld=function(a,b){var c=this.Ud(a);c&&c.ld(b)};
function rt(a,b,c,d,e){b=a.Ud(b);if(!b)return!1;for(var f=!0,g,h,l=d.da;l<=d.ba;++l)for(var m=d.ga;m<=d.ja;++m)g=a.Tb(c,l,m),h=!1,b.b.hasOwnProperty(g)&&(g=b.get(g),(h=2===g.V())&&(h=!1!==e(g))),h||(f=!1);return f}k.Rf=function(){return 0};function jw(a,b){a.wc!==b&&(a.wc=b,a.s())}k.Tb=function(a,b,c){return a+"/"+b+"/"+c};k.Uf=function(){return this.na};k.ab=function(){return this.tileGrid};k.Jb=function(a){return this.tileGrid?this.tileGrid:tc(a)};
k.Ud=function(a){var b=this.c;return b&&!bc(b,a)?null:this.a};k.pb=function(){return this.Va};k.Vd=function(a,b,c){c=this.Jb(c);b=this.pb(b);a=Ha(c.eb(a),this.l);return 1==b?a:Ga(a,b,this.l)};function kw(a,b,c){var d=void 0!==c?c:a.c;c=a.Jb(d);if(a.G&&d.g){var e=b;b=e[0];a=sc(c,e);d=uc(d);Qa(d,a)?b=e:(e=ib(d),a[0]+=e*Math.ceil((d[0]-a[0])/e),b=c.Xf(a,b))}e=b[0];d=b[1];a=b[2];if(c.minZoom>e||e>c.maxZoom)c=!1;else{var f=c.D();c=(c=f?nc(c,f,e):c.a?c.a[e]:null)?ua(c,d,a):!0}return c?b:null}
k.va=function(){this.a.clear();this.s()};k.Mg=oa;function lw(a,b){Lc.call(this,a);this.tile=b}u(lw,Lc);function mw(a){iw.call(this,{attributions:a.attributions,cacheSize:a.cacheSize,extent:a.extent,logo:a.logo,opaque:a.opaque,projection:a.projection,state:a.state,tileGrid:a.tileGrid,tilePixelRatio:a.tilePixelRatio,wrapX:a.wrapX});this.tileLoadFunction=a.tileLoadFunction;this.tileUrlFunction=this.Hc?this.Hc.bind(this):ew;this.urls=null;a.urls?this.cb(a.urls):a.url&&this.ib(a.url);a.tileUrlFunction&&this.bb(a.tileUrlFunction)}u(mw,iw);k=mw.prototype;k.ob=function(){return this.tileLoadFunction};
k.qb=function(){return this.tileUrlFunction};k.rb=function(){return this.urls};k.Fi=function(a){a=a.target;switch(a.V()){case 1:this.b(new lw("tileloadstart",a));break;case 2:this.b(new lw("tileloadend",a));break;case 3:this.b(new lw("tileloaderror",a))}};k.wb=function(a){this.a.clear();this.tileLoadFunction=a;this.s()};k.bb=function(a,b){this.tileUrlFunction=a;"undefined"!==typeof b?jw(this,b):this.s()};
k.ib=function(a){var b=this.urls=fw(a);this.bb(this.Hc?this.Hc.bind(this):cw(b,this.tileGrid),a)};k.cb=function(a){this.urls=a;var b=a.join("\n");this.bb(this.Hc?this.Hc.bind(this):cw(a,this.tileGrid),b)};k.Mg=function(a,b,c){a=this.Tb(a,b,c);this.a.b.hasOwnProperty(a)&&this.a.get(a)};function W(a){mw.call(this,{attributions:a.attributions,cacheSize:a.cacheSize,extent:a.extent,logo:a.logo,opaque:a.opaque,projection:a.projection,state:a.state,tileGrid:a.tileGrid,tileLoadFunction:a.tileLoadFunction?a.tileLoadFunction:nw,tilePixelRatio:a.tilePixelRatio,tileUrlFunction:a.tileUrlFunction,url:a.url,urls:a.urls,wrapX:a.wrapX});this.crossOrigin=void 0!==a.crossOrigin?a.crossOrigin:null;this.tileClass=a.tileClass?a.tileClass:Ks;this.f={};this.u={};this.Ha=a.reprojectionErrorThreshold;this.C=
!1}u(W,mw);k=W.prototype;k.Ei=function(){if(hw(this.a))return!0;for(var a in this.f)if(hw(this.f[a]))return!0;return!1};k.ld=function(a,b){var c=this.Ud(a);this.a.ld(this.a==c?b:{});for(var d in this.f){var e=this.f[d];e.ld(e==c?b:{})}};k.Rf=function(a){return this.c&&a&&!bc(this.c,a)?0:this.Sf()};k.Sf=function(){return 0};k.Uf=function(a){return this.c&&a&&!bc(this.c,a)?!1:mw.prototype.Uf.call(this,a)};
k.Jb=function(a){var b=this.c;return!this.tileGrid||b&&!bc(b,a)?(b=w(a).toString(),b in this.u||(this.u[b]=tc(a)),this.u[b]):this.tileGrid};k.Ud=function(a){var b=this.c;if(!b||bc(b,a))return this.a;a=w(a).toString();a in this.f||(this.f[a]=new gw(this.a.highWaterMark));return this.f[a]};function ow(a,b,c,d,e,f,g){b=[b,c,d];e=(c=kw(a,b,f))?a.tileUrlFunction(c,e,f):void 0;e=new a.tileClass(b,void 0!==e?0:4,void 0!==e?e:"",a.crossOrigin,a.tileLoadFunction);e.key=g;z(e,"change",a.Fi,a);return e}
k.Pc=function(a,b,c,d,e){if(this.c&&e&&!bc(this.c,e)){var f=this.Ud(e);c=[a,b,c];var g;a=this.Tb.apply(this,c);f.b.hasOwnProperty(a)&&(g=f.get(a));b=this.wc;if(g&&g.key==b)return g;var h=this.c,l=this.Jb(h),m=this.Jb(e),n=kw(this,c,e);d=new aw(h,l,e,m,c,n,this.pb(d),this.Sf(),function(a,b,c,d){return pw(this,a,b,c,d,h)}.bind(this),this.Ha,this.C);d.key=b;g?(d.a=g,f.replace(a,d)):f.set(a,d);return d}return pw(this,a,b,c,d,e)};
function pw(a,b,c,d,e,f){var g,h=a.Tb(b,c,d),l=a.wc;if(a.a.b.hasOwnProperty(h)){if(g=a.a.get(h),g.key!=l){var m=g;g=ow(a,b,c,d,e,f,l);0==m.V()?g.a=m.a:g.a=m;if(g.a){b=g.a;c=g;do{if(2==b.V()){b.a=null;break}else 1==b.V()?c=b:0==b.V()?c.a=b.a:c=b;b=c.a}while(b)}a.a.replace(h,g)}}else g=ow(a,b,c,d,e,f,l),a.a.set(h,g);return g}k.Ob=function(a){if(this.C!=a){this.C=a;for(var b in this.f)this.f[b].clear();this.s()}};k.Pb=function(a,b){var c=Tb(a);c&&(c=w(c).toString(),c in this.u||(this.u[c]=b))};
function nw(a,b){a.Y().src=b};function qw(a){this.A=void 0!==a.hidpi?a.hidpi:!1;W.call(this,{cacheSize:a.cacheSize,crossOrigin:"anonymous",opaque:!0,projection:Tb("EPSG:3857"),reprojectionErrorThreshold:a.reprojectionErrorThreshold,state:"loading",tileLoadFunction:a.tileLoadFunction,tilePixelRatio:this.A?2:1,wrapX:void 0!==a.wrapX?a.wrapX:!0});this.I=void 0!==a.culture?a.culture:"en-us";this.v=void 0!==a.maxZoom?a.maxZoom:-1;this.i=a.key;this.o=a.imagerySet;$v("https://dev.virtualearth.net/REST/v1/Imagery/Metadata/"+this.o+"?uriScheme=https&include=ImageryProviders&key="+
this.i,this.fa.bind(this),void 0,"jsonp")}u(qw,W);var rw=new xc({html:'<a class="ol-attribution-bing-tos" href="http://www.microsoft.com/maps/product/terms.html">Terms of Use</a>'});qw.prototype.T=function(){return this.i};qw.prototype.ea=function(){return this.o};
qw.prototype.fa=function(a){if(200!=a.statusCode||"OK"!=a.statusDescription||"ValidCredentials"!=a.authenticationResultCode||1!=a.resourceSets.length||1!=a.resourceSets[0].resources.length)Vt(this,"error");else{var b=a.brandLogoUri;-1==b.indexOf("https")&&(b=b.replace("http","https"));var c=a.resourceSets[0].resources[0],d=-1==this.v?c.zoomMax:this.v;a=uc(this.c);var e=wc({extent:a,minZoom:c.zoomMin,maxZoom:d,tileSize:(c.imageWidth==c.imageHeight?c.imageWidth:[c.imageWidth,c.imageHeight])/this.pb()});
this.tileGrid=e;var f=this.I,g=this.A;this.tileUrlFunction=dw(c.imageUrlSubdomains.map(function(a){var b=[0,0,0],d=c.imageUrl.replace("{subdomain}",a).replace("{culture}",f);return function(a){if(a)return ic(a[0],a[1],-a[2]-1,b),a=d,g&&(a+="&dpi=d1&device=mobile"),a.replace("{quadkey}",jc(b))}}));if(c.imageryProviders){var h=Sb(Tb("EPSG:4326"),this.c);a=c.imageryProviders.map(function(a){var b=a.attribution,c={};a.coverageAreas.forEach(function(a){var b=a.zoomMin,f=Math.min(a.zoomMax,d);a=a.bbox;
a=pb([a[1],a[0],a[3],a[2]],h);var g,l;for(g=b;g<=f;++g)l=g.toString(),b=nc(e,a,g),l in c?c[l].push(b):c[l]=[b]});return new xc({html:b,tileRanges:c})});a.push(rw);this.ua(a)}this.Z=b;Vt(this,"ready")}};function sw(a){a=a||{};var b=void 0!==a.projection?a.projection:"EPSG:3857",c=void 0!==a.tileGrid?a.tileGrid:wc({extent:uc(b),maxZoom:a.maxZoom,minZoom:a.minZoom,tileSize:a.tileSize});W.call(this,{attributions:a.attributions,cacheSize:a.cacheSize,crossOrigin:a.crossOrigin,logo:a.logo,opaque:a.opaque,projection:b,reprojectionErrorThreshold:a.reprojectionErrorThreshold,tileGrid:c,tileLoadFunction:a.tileLoadFunction,tilePixelRatio:a.tilePixelRatio,tileUrlFunction:a.tileUrlFunction,url:a.url,urls:a.urls,
wrapX:void 0!==a.wrapX?a.wrapX:!0})}u(sw,W);function tw(a){this.v=a.account;this.A=a.map||"";this.i=a.config||{};this.o={};sw.call(this,{attributions:a.attributions,cacheSize:a.cacheSize,crossOrigin:a.crossOrigin,logo:a.logo,maxZoom:void 0!==a.maxZoom?a.maxZoom:18,minZoom:a.minZoom,projection:a.projection,state:"loading",wrapX:a.wrapX});uw(this)}u(tw,sw);k=tw.prototype;k.Gk=function(){return this.i};k.iq=function(a){qb(this.i,a);uw(this)};k.Np=function(a){this.i=a||{};uw(this)};
function uw(a){var b=JSON.stringify(a.i);if(a.o[b])vw(a,a.o[b]);else{var c="https://"+a.v+".cartodb.com/api/v1/map";a.A&&(c+="/named/"+a.A);var d=new XMLHttpRequest;d.addEventListener("load",a.yl.bind(a,b));d.addEventListener("error",a.xl.bind(a));d.open("POST",c);d.setRequestHeader("Content-type","application/json");d.send(JSON.stringify(a.i))}}
k.yl=function(a,b){var c=b.target;if(!c.status||200<=c.status&&300>c.status){var d;try{d=JSON.parse(c.responseText)}catch(e){Vt(this,"error");return}vw(this,d);this.o[a]=d;Vt(this,"ready")}else Vt(this,"error")};k.xl=function(){Vt(this,"error")};function vw(a,b){a.ib("https://"+b.cdn_url.https+"/"+a.v+"/api/v1/map/"+b.layergroupid+"/{z}/{x}/{y}.png")};function X(a){T.call(this,{attributions:a.attributions,extent:a.extent,logo:a.logo,projection:a.projection,wrapX:a.wrapX});this.C=void 0;this.I=void 0!==a.distance?a.distance:20;this.A=[];this.Qa=a.geometryFunction||function(a){a=a.U();sa(a instanceof E,10);return a};this.v=a.source;this.v.J("change",X.prototype.bj,this)}u(X,T);k=X.prototype;k.Qn=function(){return this.I};k.Rn=function(){return this.v};k.Xd=function(a,b,c){this.v.Xd(a,b,c);b!==this.C&&(this.clear(),this.C=b,ww(this),this.gd(this.A))};
k.Op=function(a){this.I=a;this.bj()};k.bj=function(){this.clear();ww(this);this.gd(this.A);this.s()};function ww(a){if(void 0!==a.C){a.A.length=0;for(var b=Ja(),c=a.I*a.C,d=a.v.We(),e={},f=0,g=d.length;f<g;f++){var h=d[f];w(h).toString()in e||!(h=a.Qa(h))||(h=h.W(),Xa(h,b),Ma(b,c,b),h=a.v.Pf(b),h=h.filter(function(a){a=w(a).toString();return a in e?!1:e[a]=!0}),a.A.push(xw(a,h)))}}}
function xw(a,b){for(var c=[0,0],d=b.length-1;0<=d;--d){var e=a.Qa(b[d]);e?Xe(c,e.W()):b.splice(d,1)}df(c,1/b.length);c=new I(new E(c));c.set("features",b);return c};function yw(a,b){var c=[];Object.keys(b).forEach(function(a){null!==b[a]&&void 0!==b[a]&&c.push(a+"="+encodeURIComponent(b[a]))});var d=c.join("&");a=a.replace(/[?&]$/,"");a=-1===a.indexOf("?")?a+"?":a+"&";return a+d};function zw(a){a=a||{};zv.call(this,{attributions:a.attributions,logo:a.logo,projection:a.projection,resolutions:a.resolutions});this.I=void 0!==a.crossOrigin?a.crossOrigin:null;this.T=void 0!==a.hidpi?a.hidpi:!0;this.i=a.url;this.f=a.imageLoadFunction?a.imageLoadFunction:Fv;this.u=a.params||{};this.N=null;this.o=[0,0];this.C=0;this.A=void 0!==a.ratio?a.ratio:1.5}u(zw,zv);k=zw.prototype;k.Tn=function(){return this.u};
k.Lc=function(a,b,c,d){if(void 0===this.i)return null;b=Av(this,b);c=this.T?c:1;var e=this.N;if(e&&this.C==this.g&&e.resolution==b&&e.a==c&&Ua(e.D(),a))return e;e={F:"image",FORMAT:"PNG32",TRANSPARENT:!0};qb(e,this.u);a=a.slice();var f=(a[0]+a[2])/2,g=(a[1]+a[3])/2;if(1!=this.A){var h=this.A*ib(a)/2,l=this.A*jb(a)/2;a[0]=f-h;a[1]=g-l;a[2]=f+h;a[3]=g+l}var h=b/c,l=Math.ceil(ib(a)/h),m=Math.ceil(jb(a)/h);a[0]=f-h*l/2;a[2]=f+h*l/2;a[1]=g-h*m/2;a[3]=g+h*m/2;this.o[0]=l;this.o[1]=m;f=a;g=this.o;h=c;d=
d.nb.split(":").pop();e.SIZE=g[0]+","+g[1];e.BBOX=f.join(",");e.BBOXSR=d;e.IMAGESR=d;e.DPI=Math.round(90*h);d=this.i;f=d.replace(/MapServer\/?$/,"MapServer/export").replace(/ImageServer\/?$/,"ImageServer/exportImage");f==d&&sa(!1,50);e=yw(f,e);this.N=new Gs(a,b,c,this.j,e,this.I,this.f);this.C=this.g;z(this.N,"change",this.l,this);return this.N};k.Sn=function(){return this.f};k.Un=function(){return this.i};k.Vn=function(a){this.N=null;this.f=a;this.s()};
k.Wn=function(a){a!=this.i&&(this.i=a,this.N=null,this.s())};k.Xn=function(a){qb(this.u,a);this.N=null;this.s()};function Aw(a){zv.call(this,{projection:a.projection,resolutions:a.resolutions});this.I=void 0!==a.crossOrigin?a.crossOrigin:null;this.o=void 0!==a.displayDpi?a.displayDpi:96;this.f=a.params||{};this.C=a.url;this.i=a.imageLoadFunction?a.imageLoadFunction:Fv;this.T=void 0!==a.hidpi?a.hidpi:!0;this.fa=void 0!==a.metersPerUnit?a.metersPerUnit:1;this.u=void 0!==a.ratio?a.ratio:1;this.na=void 0!==a.useOverlay?a.useOverlay:!1;this.N=null;this.A=0}u(Aw,zv);k=Aw.prototype;k.Zn=function(){return this.f};
k.Lc=function(a,b,c){b=Av(this,b);c=this.T?c:1;var d=this.N;if(d&&this.A==this.g&&d.resolution==b&&d.a==c&&Ua(d.D(),a))return d;1!=this.u&&(a=a.slice(),ob(a,this.u));var e=[ib(a)/b*c,jb(a)/b*c];if(void 0!==this.C){var d=this.C,f=kb(a),g=this.fa,h=ib(a),l=jb(a),m=e[0],n=e[1],p=.0254/this.o,e={OPERATION:this.na?"GETDYNAMICMAPOVERLAYIMAGE":"GETMAPIMAGE",VERSION:"2.0.0",LOCALE:"en",CLIENTAGENT:"ol.source.ImageMapGuide source",CLIP:"1",SETDISPLAYDPI:this.o,SETDISPLAYWIDTH:Math.round(e[0]),SETDISPLAYHEIGHT:Math.round(e[1]),
SETVIEWSCALE:n*h>m*l?h*g/(m*p):l*g/(n*p),SETVIEWCENTERX:f[0],SETVIEWCENTERY:f[1]};qb(e,this.f);d=yw(d,e);d=new Gs(a,b,c,this.j,d,this.I,this.i);z(d,"change",this.l,this)}else d=null;this.N=d;this.A=this.g;return d};k.Yn=function(){return this.i};k.ao=function(a){qb(this.f,a);this.s()};k.$n=function(a){this.N=null;this.i=a;this.s()};function Bw(a){var b=a.imageExtent,c=void 0!==a.crossOrigin?a.crossOrigin:null,d=a.imageLoadFunction?a.imageLoadFunction:Fv;zv.call(this,{attributions:a.attributions,logo:a.logo,projection:Tb(a.projection)});this.N=new Gs(b,void 0,1,this.j,a.url,c,d);this.i=a.imageSize?a.imageSize:null;z(this.N,"change",this.l,this)}u(Bw,zv);Bw.prototype.Lc=function(a){return nb(a,this.N.D())?this.N:null};
Bw.prototype.l=function(a){if(2==this.N.V()){var b=this.N.D(),c=this.N.Y(),d,e;this.i?(d=this.i[0],e=this.i[1]):(d=c.width,e=c.height);b=Math.ceil(ib(b)/(jb(b)/e));if(b!=d){var b=hd(b,e),f=b.canvas;b.drawImage(c,0,0,d,e,0,0,f.width,f.height);this.N.Hg(f)}}zv.prototype.l.call(this,a)};function Cw(a){a=a||{};zv.call(this,{attributions:a.attributions,logo:a.logo,projection:a.projection,resolutions:a.resolutions});this.fa=void 0!==a.crossOrigin?a.crossOrigin:null;this.f=a.url;this.u=a.imageLoadFunction?a.imageLoadFunction:Fv;this.i=a.params||{};this.o=!0;Dw(this);this.T=a.serverType;this.na=void 0!==a.hidpi?a.hidpi:!0;this.N=null;this.A=[0,0];this.I=0;this.C=void 0!==a.ratio?a.ratio:1.5}u(Cw,zv);var Ew=[101,101];k=Cw.prototype;
k.io=function(a,b,c,d){if(void 0!==this.f){var e=lb(a,b,0,Ew),f={SERVICE:"WMS",VERSION:"1.3.0",REQUEST:"GetFeatureInfo",FORMAT:"image/png",TRANSPARENT:!0,QUERY_LAYERS:this.i.LAYERS};qb(f,this.i,d);d=Math.floor((e[3]-a[1])/b);f[this.o?"I":"X"]=Math.floor((a[0]-e[0])/b);f[this.o?"J":"Y"]=d;return Fw(this,e,Ew,1,Tb(c),f)}};k.ko=function(){return this.i};
k.Lc=function(a,b,c,d){if(void 0===this.f)return null;b=Av(this,b);1==c||this.na&&void 0!==this.T||(c=1);var e=b/c,f=kb(a),g=lb(f,e,0,[Math.ceil(ib(a)/e),Math.ceil(jb(a)/e)]);a=lb(f,e,0,[Math.ceil(this.C*ib(a)/e),Math.ceil(this.C*jb(a)/e)]);if((f=this.N)&&this.I==this.g&&f.resolution==b&&f.a==c&&Ua(f.D(),g))return f;g={SERVICE:"WMS",VERSION:"1.3.0",REQUEST:"GetMap",FORMAT:"image/png",TRANSPARENT:!0};qb(g,this.i);this.A[0]=Math.round(ib(a)/e);this.A[1]=Math.round(jb(a)/e);d=Fw(this,a,this.A,c,d,g);
this.N=new Gs(a,b,c,this.j,d,this.fa,this.u);this.I=this.g;z(this.N,"change",this.l,this);return this.N};k.jo=function(){return this.u};
function Fw(a,b,c,d,e,f){sa(void 0!==a.f,9);f[a.o?"CRS":"SRS"]=e.nb;"STYLES"in a.i||(f.STYLES="");if(1!=d)switch(a.T){case "geoserver":d=90*d+.5|0;f.FORMAT_OPTIONS="FORMAT_OPTIONS"in f?f.FORMAT_OPTIONS+(";dpi:"+d):"dpi:"+d;break;case "mapserver":f.MAP_RESOLUTION=90*d;break;case "carmentaserver":case "qgis":f.DPI=90*d;break;default:sa(!1,8)}f.WIDTH=c[0];f.HEIGHT=c[1];c=e.b;var g;a.o&&"ne"==c.substr(0,2)?g=[b[1],b[0],b[3],b[2]]:g=b;f.BBOX=g.join(",");return yw(a.f,f)}k.lo=function(){return this.f};
k.mo=function(a){this.N=null;this.u=a;this.s()};k.no=function(a){a!=this.f&&(this.f=a,this.N=null,this.s())};k.oo=function(a){qb(this.i,a);Dw(this);this.N=null;this.s()};function Dw(a){a.o=0<=We(a.i.VERSION||"1.3.0")};function Gw(a){a=a||{};var b;void 0!==a.attributions?b=a.attributions:b=[Hw];sw.call(this,{attributions:b,cacheSize:a.cacheSize,crossOrigin:void 0!==a.crossOrigin?a.crossOrigin:"anonymous",opaque:void 0!==a.opaque?a.opaque:!0,maxZoom:void 0!==a.maxZoom?a.maxZoom:19,reprojectionErrorThreshold:a.reprojectionErrorThreshold,tileLoadFunction:a.tileLoadFunction,url:void 0!==a.url?a.url:"https://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png",wrapX:a.wrapX})}u(Gw,sw);var Hw=new xc({html:'&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors.'});(function(){var a={},b={ma:a};(function(c){if("object"===typeof a&&"undefined"!==typeof b)b.ma=c();else{var d;"undefined"!==typeof window?d=window:"undefined"!==typeof global?d=global:"undefined"!==typeof self?d=self:d=this;d.Cq=c()}})(function(){return function d(a,b,g){function e(h,l){if(!b[h]){if(!a[h]){var m="function"==typeof require&&require;if(!l&&m)return m(h,!0);if(f)return f(h,!0);m=Error("Cannot find module '"+h+"'");throw m.code="MODULE_NOT_FOUND",m;}m=b[h]={ma:{}};a[h][0].call(m.ma,function(b){var d=
a[h][1][b];return e(d?d:b)},m,m.ma,d,a,b,g)}return b[h].ma}for(var f="function"==typeof require&&require,m=0;m<g.length;m++)e(g[m]);return e}({1:[function(a,b,f){a=a("./processor");f.Pj=a},{"./processor":2}],2:[function(a,b){function d(a){var b=!0;try{new ImageData(10,10)}catch(q){b=!1}return function(d){var e=d.buffers,f=d.meta,g=d.width,h=d.height,l=e.length,m=e[0].byteLength;if(d.imageOps){m=Array(l);for(d=0;d<l;++d){var n=m,p=d,q;q=new Uint8ClampedArray(e[d]);var Ka=g,C=h;q=b?new ImageData(q,
Ka,C):{data:q,width:Ka,height:C};n[p]=q}g=a(m,f).data}else{g=new Uint8ClampedArray(m);h=Array(l);n=Array(l);for(d=0;d<l;++d)h[d]=new Uint8ClampedArray(e[d]),n[d]=[0,0,0,0];for(e=0;e<m;e+=4){for(d=0;d<l;++d)p=h[d],n[d][0]=p[e],n[d][1]=p[e+1],n[d][2]=p[e+2],n[d][3]=p[e+3];d=a(n,f);g[e]=d[0];g[e+1]=d[1];g[e+2]=d[2];g[e+3]=d[3]}}return g.buffer}}function e(a,b){var e=Object.keys(a.lib||{}).map(function(b){return"var "+b+" = "+a.lib[b].toString()+";"}).concat(["var __minion__ = ("+d.toString()+")(",a.operation.toString(),
");",'self.addEventListener("message", function(event) {',"  var buffer = __minion__(event.data);","  self.postMessage({buffer: buffer, meta: event.data.meta}, [buffer]);","});"]),e=URL.createObjectURL(new Blob(e,{type:"text/javascript"})),e=new Worker(e);e.addEventListener("message",b);return e}function h(a,b){var e=d(a.operation);return{postMessage:function(a){setTimeout(function(){b({data:{buffer:e(a),meta:a.meta}})},0)}}}function l(a){this.Bf=!!a.Vl;var b;0===a.threads?b=0:this.Bf?b=1:b=a.threads||
1;var d=[];if(b)for(var f=0;f<b;++f)d[f]=e(a,this.Yg.bind(this,f));else d[0]=h(a,this.Yg.bind(this,0));this.qe=d;this.Fd=[];this.bk=a.hp||Infinity;this.oe=0;this.fd={};this.Cf=null}var m=a("./util").om;l.prototype.fp=function(a,b,d){this.$j({inputs:a,Jh:b,jd:d});this.Vg()};l.prototype.$j=function(a){for(this.Fd.push(a);this.Fd.length>this.bk;)this.Fd.shift().jd(null,null)};l.prototype.Vg=function(){if(0===this.oe&&0<this.Fd.length){var a=this.Cf=this.Fd.shift(),b=a.inputs[0].width,d=a.inputs[0].height,
e=a.inputs.map(function(a){return a.data.buffer}),f=this.qe.length;this.oe=f;if(1===f)this.qe[0].postMessage({buffers:e,meta:a.Jh,imageOps:this.Bf,width:b,height:d},e);else for(var g=4*Math.ceil(a.inputs[0].data.length/4/f),h=0;h<f;++h){for(var l=h*g,m=[],aa=0,Ra=e.length;aa<Ra;++aa)m.push(e[h].slice(l,l+g));this.qe[h].postMessage({buffers:m,meta:a.Jh,imageOps:this.Bf,width:b,height:d},m)}}};l.prototype.Yg=function(a,b){this.Aq||(this.fd[a]=b.data,--this.oe,0===this.oe&&this.ck())};l.prototype.ck=
function(){var a=this.Cf,b=this.qe.length,d,e;if(1===b)d=new Uint8ClampedArray(this.fd[0].buffer),e=this.fd[0].meta;else{var f=a.inputs[0].data.length;d=new Uint8ClampedArray(f);e=Array(f);for(var f=4*Math.ceil(f/4/b),g=0;g<b;++g){var h=g*f;d.set(new Uint8ClampedArray(this.fd[g].buffer),h);e[g]=this.fd[g].meta}}this.Cf=null;this.fd={};a.jd(null,m(d,a.inputs[0].width,a.inputs[0].height),e);this.Vg()};b.ma=l},{"./util":3}],3:[function(a,b,f){var d=!0;try{new ImageData(10,10)}catch(l){d=!1}var e=document.createElement("canvas").getContext("2d");
f.om=function(a,b,f){if(d)return new ImageData(a,b,f);b=e.createImageData(b,f);b.data.set(a);return b}},{}]},{},[1])(1)});Fj=b.ma})();function Iw(a){this.A=null;this.na=void 0!==a.operationType?a.operationType:"pixel";this.Ha=void 0!==a.threads?a.threads:1;this.f=Jw(a.sources);for(var b=0,c=this.f.length;b<c;++b)z(this.f[b],"change",this.s,this);this.T=new Ne(function(){return 1},this.s.bind(this));for(var b=Kw(this.f),c={},d=0,e=b.length;d<e;++d)c[w(b[d].layer)]=b[d];this.i=null;this.C={animate:!1,attributions:{},coordinateToPixelTransform:yh(),extent:null,focus:null,index:0,layerStates:c,layerStatesArray:b,logos:{},pixelRatio:1,
pixelToCoordinateTransform:yh(),postRenderFunctions:[],size:[0,0],skippedFeatureUids:{},tileQueue:this.T,time:Date.now(),usedTiles:{},viewState:{rotation:0},viewHints:[],wantedTiles:{}};zv.call(this,{});a.operation&&this.u(a.operation,a.lib)}u(Iw,zv);Iw.prototype.u=function(a,b){this.A=new Fj.Pj({operation:a,Vl:"image"===this.na,hp:1,lib:b,threads:this.Ha});this.s()};
Iw.prototype.Y=function(a,b,c,d){c=!0;for(var e,f=0,g=this.f.length;f<g;++f)if(e=this.f[f].a.ka(),"ready"!==e.V()){c=!1;break}if(!c)return null;c=qb({},this.C);c.viewState=qb({},c.viewState);e=kb(a);c.extent=a.slice();c.focus=e;c.size[0]=Math.round(ib(a)/b);c.size[1]=Math.round(jb(a)/b);f=c.viewState;f.center=e;f.projection=d;f.resolution=b;this.o=c;Oe(c.tileQueue,16,16);this.i&&(d=this.i.resolution,c=this.i.D(),b===d&&$a(a,c)||(this.i=null));if(!this.i||this.g!==this.I)a:{a=this.o;d=this.f.length;
b=Array(d);for(c=0;c<d;++c){e=this.f[c];f=a;g=a.layerStatesArray[c];if(e.ud(f,g)){var h=f.size[0],l=f.size[1];if(Lw){var m=Lw.canvas;m.width!==h||m.height!==l?Lw=hd(h,l):Lw.clearRect(0,0,h,l)}else Lw=hd(h,l);e.O(f,g,Lw);e=Lw.getImageData(0,0,h,l)}else e=null;if(e)b[c]=e;else break a}d={};this.b(new Mw(Nw,a,d));this.A.fp(b,d,this.fa.bind(this,a))}return this.i};
Iw.prototype.fa=function(a,b,c,d){if(!b&&c){b=a.extent;var e=a.viewState.resolution;if(e===this.o.viewState.resolution&&$a(b,this.o.extent)){var f;this.i?f=this.i.Y().getContext("2d"):(f=hd(Math.round(ib(b)/e),Math.round(jb(b)/e)),this.i=new Hs(b,e,1,this.j,f.canvas));f.putImageData(c,0,0);this.s();this.I=this.g;this.b(new Mw(Ow,a,d))}}};var Lw=null;function Kw(a){return a.map(function(a){return qh(a.a)})}
function Jw(a){for(var b=a.length,c=Array(b),d=0;d<b;++d){var e=d,f=a[d],g=null;f instanceof iw?(f=new Vv({source:f}),g=new Nv(f)):f instanceof zv&&(f=new Mv({source:f}),g=new rv(f));c[e]=g}return c}function Mw(a,b,c){Lc.call(this,a);this.extent=b.extent;this.resolution=b.viewState.resolution/b.pixelRatio;this.data=c}u(Mw,Lc);Iw.prototype.Lc=function(){return null};var Nw="beforeoperations",Ow="afteroperations";function Pw(a){var b=a.layer.indexOf("-"),b=Qw[-1==b?a.layer:a.layer.slice(0,b)],c=Rw[a.layer];sw.call(this,{attributions:Sw,cacheSize:a.cacheSize,crossOrigin:"anonymous",maxZoom:void 0!=a.maxZoom?a.maxZoom:b.maxZoom,minZoom:void 0!=a.minZoom?a.minZoom:b.minZoom,opaque:c.opaque,reprojectionErrorThreshold:a.reprojectionErrorThreshold,tileLoadFunction:a.tileLoadFunction,url:void 0!==a.url?a.url:"https://stamen-tiles-{a-d}.a.ssl.fastly.net/"+a.layer+"/{z}/{x}/{y}."+c.Ib})}u(Pw,sw);
var Sw=[new xc({html:'Map tiles by <a href="http://stamen.com/">Stamen Design</a>, under <a href="http://creativecommons.org/licenses/by/3.0/">CC BY 3.0</a>.'}),Hw],Rw={terrain:{Ib:"jpg",opaque:!0},"terrain-background":{Ib:"jpg",opaque:!0},"terrain-labels":{Ib:"png",opaque:!1},"terrain-lines":{Ib:"png",opaque:!1},"toner-background":{Ib:"png",opaque:!0},toner:{Ib:"png",opaque:!0},"toner-hybrid":{Ib:"png",opaque:!1},"toner-labels":{Ib:"png",opaque:!1},"toner-lines":{Ib:"png",opaque:!1},"toner-lite":{Ib:"png",
opaque:!0},watercolor:{Ib:"jpg",opaque:!0}},Qw={terrain:{minZoom:4,maxZoom:18},toner:{minZoom:0,maxZoom:20},watercolor:{minZoom:1,maxZoom:16}};function Tw(a){a=a||{};W.call(this,{attributions:a.attributions,cacheSize:a.cacheSize,crossOrigin:a.crossOrigin,logo:a.logo,projection:a.projection,reprojectionErrorThreshold:a.reprojectionErrorThreshold,tileGrid:a.tileGrid,tileLoadFunction:a.tileLoadFunction,url:a.url,urls:a.urls,wrapX:void 0!==a.wrapX?a.wrapX:!0});this.i=a.params||{};this.o=Ja();jw(this,Uw(this))}u(Tw,W);function Uw(a){var b=0,c=[],d;for(d in a.i)c[b++]=d+"-"+a.i[d];return c.join("/")}Tw.prototype.v=function(){return this.i};
Tw.prototype.pb=function(a){return a};
Tw.prototype.Hc=function(a,b,c){var d=this.tileGrid;d||(d=this.Jb(c));if(!(d.b.length<=a[0])){var e=d.Ua(a,this.o),f=Ha(d.eb(a[0]),this.l);1!=b&&(f=Ga(f,b,this.l));d={F:"image",FORMAT:"PNG32",TRANSPARENT:!0};qb(d,this.i);var g=this.urls;g?(c=c.nb.split(":").pop(),d.SIZE=f[0]+","+f[1],d.BBOX=e.join(","),d.BBOXSR=c,d.IMAGESR=c,d.DPI=Math.round(d.DPI?d.DPI*b:90*b),a=(1==g.length?g[0]:g[Da((a[1]<<a[0])+a[2],g.length)]).replace(/MapServer\/?$/,"MapServer/export").replace(/ImageServer\/?$/,"ImageServer/exportImage"),
a=yw(a,d)):a=void 0;return a}};Tw.prototype.A=function(a){qb(this.i,a);jw(this,Uw(this))};function Vw(a){iw.call(this,{opaque:!1,projection:a.projection,tileGrid:a.tileGrid,wrapX:void 0!==a.wrapX?a.wrapX:!0})}u(Vw,iw);Vw.prototype.Pc=function(a,b,c){var d=this.Tb(a,b,c);if(this.a.b.hasOwnProperty(d))return this.a.get(d);var e=Ha(this.tileGrid.eb(a));a=[a,b,c];b=(b=kw(this,a))?kw(this,b).toString():"";e=new Ww(a,e,b);this.a.set(d,e);return e};function Ww(a,b,c){Is.call(this,a,2);this.c=b;this.Fa=c;this.g=null}u(Ww,Is);
Ww.prototype.Y=function(){if(this.g)return this.g;var a=this.c,b=hd(a[0],a[1]);b.strokeStyle="black";b.strokeRect(.5,.5,a[0]+.5,a[1]+.5);b.fillStyle="black";b.textAlign="center";b.textBaseline="middle";b.font="24px sans-serif";b.fillText(this.Fa,a[0]/2,a[1]/2);return this.g=b.canvas};Ww.prototype.load=function(){};function Xw(a){this.i=null;W.call(this,{attributions:a.attributions,cacheSize:a.cacheSize,crossOrigin:a.crossOrigin,projection:Tb("EPSG:3857"),reprojectionErrorThreshold:a.reprojectionErrorThreshold,state:"loading",tileLoadFunction:a.tileLoadFunction,wrapX:void 0!==a.wrapX?a.wrapX:!0});if(a.jsonp)$v(a.url,this.Ci.bind(this),this.Ue.bind(this));else{var b=new XMLHttpRequest;b.addEventListener("load",this.qo.bind(this));b.addEventListener("error",this.po.bind(this));b.open("GET",a.url);b.send()}}
u(Xw,W);k=Xw.prototype;k.qo=function(a){a=a.target;if(!a.status||200<=a.status&&300>a.status){var b;try{b=JSON.parse(a.responseText)}catch(c){this.Ue();return}this.Ci(b)}else this.Ue()};k.po=function(){this.Ue()};k.kl=function(){return this.i};
k.Ci=function(a){var b=Tb("EPSG:4326"),c=this.c,d;if(a.bounds){var e=Sb(b,c);d=pb(a.bounds,e)}var f=a.minzoom||0,e=a.maxzoom||22;this.tileGrid=c=wc({extent:uc(c),maxZoom:e,minZoom:f});this.tileUrlFunction=cw(a.tiles,c);if(void 0!==a.attribution&&!this.j){b=void 0!==d?d:b.D();d={};for(var g;f<=e;++f)g=f.toString(),d[g]=[nc(c,b,f)];this.ua([new xc({html:a.attribution,tileRanges:d})])}this.i=a;Vt(this,"ready")};k.Ue=function(){Vt(this,"error")};function Yw(a){iw.call(this,{projection:Tb("EPSG:3857"),state:"loading"});this.u=void 0!==a.preemptive?a.preemptive:!0;this.o=ew;this.f=void 0;this.i=a.jsonp||!1;if(a.url)if(this.i)$v(a.url,this.jg.bind(this),this.Ve.bind(this));else{var b=new XMLHttpRequest;b.addEventListener("load",this.uo.bind(this));b.addEventListener("error",this.to.bind(this));b.open("GET",a.url);b.send()}else a.tileJSON?this.jg(a.tileJSON):sa(!1,51)}u(Yw,iw);k=Yw.prototype;
k.uo=function(a){a=a.target;if(!a.status||200<=a.status&&300>a.status){var b;try{b=JSON.parse(a.responseText)}catch(c){this.Ve();return}this.jg(b)}else this.Ve()};k.to=function(){this.Ve()};k.hl=function(){return this.f};k.vk=function(a,b,c,d,e){this.tileGrid?(b=this.tileGrid.Ae(a,b),Zw(this.Pc(b[0],b[1],b[2],1,this.c),a,c,d,e)):!0===e?setTimeout(function(){c.call(d,null)},0):c.call(d,null)};k.Ve=function(){Vt(this,"error")};
k.jg=function(a){var b=Tb("EPSG:4326"),c=this.c,d;if(a.bounds){var e=Sb(b,c);d=pb(a.bounds,e)}var f=a.minzoom||0,e=a.maxzoom||22;this.tileGrid=c=wc({extent:uc(c),maxZoom:e,minZoom:f});this.f=a.template;var g=a.grids;if(g){this.o=cw(g,c);if(void 0!==a.attribution){b=void 0!==d?d:b.D();for(d={};f<=e;++f)g=f.toString(),d[g]=[nc(c,b,f)];this.ua([new xc({html:a.attribution,tileRanges:d})])}Vt(this,"ready")}else Vt(this,"error")};
k.Pc=function(a,b,c,d,e){var f=this.Tb(a,b,c);if(this.a.b.hasOwnProperty(f))return this.a.get(f);a=[a,b,c];b=kw(this,a,e);d=this.o(b,d,e);d=new $w(a,void 0!==d?0:4,void 0!==d?d:"",this.tileGrid.Ua(a),this.u,this.i);this.a.set(f,d);return d};k.Mg=function(a,b,c){a=this.Tb(a,b,c);this.a.b.hasOwnProperty(a)&&this.a.get(a)};function $w(a,b,c,d,e,f){Is.call(this,a,b);this.o=c;this.g=d;this.v=e;this.c=this.l=this.f=null;this.u=f}u($w,Is);k=$w.prototype;k.Y=function(){return null};
k.getData=function(a){if(!this.f||!this.l)return null;var b=this.f[Math.floor((1-(a[1]-this.g[1])/(this.g[3]-this.g[1]))*this.f.length)];if("string"!==typeof b)return null;b=b.charCodeAt(Math.floor((a[0]-this.g[0])/(this.g[2]-this.g[0])*b.length));93<=b&&b--;35<=b&&b--;b-=32;a=null;b in this.l&&(b=this.l[b],this.c&&b in this.c?a=this.c[b]:a=b);return a};
function Zw(a,b,c,d,e){0==a.state&&!0===e?(Gc(a,"change",function(){c.call(d,this.getData(b))},a),ax(a)):!0===e?setTimeout(function(){c.call(d,this.getData(b))}.bind(a),0):c.call(d,a.getData(b))}k.hb=function(){return this.o};k.Ce=function(){this.state=3;this.s()};k.Di=function(a){this.f=a.grid;this.l=a.keys;this.c=a.data;this.state=4;this.s()};
function ax(a){if(0==a.state)if(a.state=1,a.u)$v(a.o,a.Di.bind(a),a.Ce.bind(a));else{var b=new XMLHttpRequest;b.addEventListener("load",a.so.bind(a));b.addEventListener("error",a.ro.bind(a));b.open("GET",a.o);b.send()}}k.so=function(a){a=a.target;if(!a.status||200<=a.status&&300>a.status){var b;try{b=JSON.parse(a.responseText)}catch(c){this.Ce();return}this.Di(b)}else this.Ce()};k.ro=function(){this.Ce()};k.load=function(){this.v&&ax(this)};function bx(a){a=a||{};var b=a.params||{};W.call(this,{attributions:a.attributions,cacheSize:a.cacheSize,crossOrigin:a.crossOrigin,logo:a.logo,opaque:!("TRANSPARENT"in b?b.TRANSPARENT:1),projection:a.projection,reprojectionErrorThreshold:a.reprojectionErrorThreshold,tileGrid:a.tileGrid,tileLoadFunction:a.tileLoadFunction,url:a.url,urls:a.urls,wrapX:void 0!==a.wrapX?a.wrapX:!0});this.v=void 0!==a.gutter?a.gutter:0;this.i=b;this.o=!0;this.A=a.serverType;this.T=void 0!==a.hidpi?a.hidpi:!0;this.I="";
cx(this);this.ea=Ja();dx(this);jw(this,ex(this))}u(bx,W);k=bx.prototype;
k.vo=function(a,b,c,d){c=Tb(c);var e=this.tileGrid;e||(e=this.Jb(c));b=e.Ae(a,b);if(!(e.b.length<=b[0])){var f=e.La(b[0]),g=e.Ua(b,this.ea),e=Ha(e.eb(b[0]),this.l),h=this.v;h&&(e=Fa(e,h,this.l),g=Ma(g,f*h,g));h={SERVICE:"WMS",VERSION:"1.3.0",REQUEST:"GetFeatureInfo",FORMAT:"image/png",TRANSPARENT:!0,QUERY_LAYERS:this.i.LAYERS};qb(h,this.i,d);d=Math.floor((g[3]-a[1])/f);h[this.o?"I":"X"]=Math.floor((a[0]-g[0])/f);h[this.o?"J":"Y"]=d;return fx(this,b,e,g,1,c,h)}};k.Sf=function(){return this.v};
k.Tb=function(a,b,c){return this.I+W.prototype.Tb.call(this,a,b,c)};k.wo=function(){return this.i};
function fx(a,b,c,d,e,f,g){var h=a.urls;if(h){g.WIDTH=c[0];g.HEIGHT=c[1];g[a.o?"CRS":"SRS"]=f.nb;"STYLES"in a.i||(g.STYLES="");if(1!=e)switch(a.A){case "geoserver":c=90*e+.5|0;g.FORMAT_OPTIONS="FORMAT_OPTIONS"in g?g.FORMAT_OPTIONS+(";dpi:"+c):"dpi:"+c;break;case "mapserver":g.MAP_RESOLUTION=90*e;break;case "carmentaserver":case "qgis":g.DPI=90*e;break;default:sa(!1,52)}f=f.b;a.o&&"ne"==f.substr(0,2)&&(a=d[0],d[0]=d[1],d[1]=a,a=d[2],d[2]=d[3],d[3]=a);g.BBOX=d.join(",");return yw(1==h.length?h[0]:h[Da((b[1]<<
b[0])+b[2],h.length)],g)}}k.pb=function(a){return this.T&&void 0!==this.A?a:1};function cx(a){var b=0,c=[];if(a.urls){var d,e;d=0;for(e=a.urls.length;d<e;++d)c[b++]=a.urls[d]}a.I=c.join("#")}function ex(a){var b=0,c=[],d;for(d in a.i)c[b++]=d+"-"+a.i[d];return c.join("/")}
k.Hc=function(a,b,c){var d=this.tileGrid;d||(d=this.Jb(c));if(!(d.b.length<=a[0])){1==b||this.T&&void 0!==this.A||(b=1);var e=d.La(a[0]),f=d.Ua(a,this.ea),d=Ha(d.eb(a[0]),this.l),g=this.v;g&&(d=Fa(d,g,this.l),f=Ma(f,e*g,f));1!=b&&(d=Ga(d,b,this.l));e={SERVICE:"WMS",VERSION:"1.3.0",REQUEST:"GetMap",FORMAT:"image/png",TRANSPARENT:!0};qb(e,this.i);return fx(this,a,d,f,b,c,e)}};k.cb=function(a){W.prototype.cb.call(this,a);cx(this)};k.xo=function(a){qb(this.i,a);cx(this);dx(this);jw(this,ex(this))};
function dx(a){a.o=0<=We(a.i.VERSION||"1.3.0")};function gx(a,b,c,d,e){Is.call(this,a,b);this.c=null;this.l=d;this.f=null;this.g={Od:!1,Eg:null,kf:-1,Fg:-1,zd:null};this.v=e;this.o=c}u(gx,Is);k=gx.prototype;k.Y=function(){return-1==this.g.Fg?null:this.c.canvas};k.Gm=function(){return this.l};k.hb=function(){return this.o};k.load=function(){0==this.state&&(this.state=1,this.s(),this.v(this,this.o),this.u(null,NaN,null))};k.Qo=function(a,b){this.dg(b);this.hj(a)};k.Po=function(){this.state=3;this.s()};k.hj=function(a){this.f=a;this.state=2;this.s()};
k.dg=function(a){this.j=a};k.mj=function(a){this.u=a};function hx(a,b){a.mj(Cl(b,a.l,a.Qo.bind(a),a.Po.bind(a)))};function ix(a){mw.call(this,{attributions:a.attributions,cacheSize:void 0!==a.cacheSize?a.cacheSize:128,extent:a.extent,logo:a.logo,opaque:!1,projection:a.projection,state:a.state,tileGrid:a.tileGrid,tileLoadFunction:a.tileLoadFunction?a.tileLoadFunction:hx,tileUrlFunction:a.tileUrlFunction,tilePixelRatio:a.tilePixelRatio,url:a.url,urls:a.urls,wrapX:void 0===a.wrapX?!0:a.wrapX});this.i=a.format?a.format:null;this.f=void 0==a.overlaps?!0:a.overlaps;this.tileClass=a.tileClass?a.tileClass:gx}u(ix,mw);
ix.prototype.Pc=function(a,b,c,d,e){var f=this.Tb(a,b,c);if(this.a.b.hasOwnProperty(f))return this.a.get(f);a=[a,b,c];d=(b=kw(this,a,e))?this.tileUrlFunction(b,d,e):void 0;d=new this.tileClass(a,void 0!==d?0:4,void 0!==d?d:"",this.i,this.tileLoadFunction);z(d,"change",this.Fi,this);this.a.set(f,d);return d};ix.prototype.pb=function(a){return void 0==a?mw.prototype.pb.call(this,a):a};ix.prototype.Vd=function(a,b){var c=Ha(this.tileGrid.eb(a));return[Math.round(c[0]*b),Math.round(c[1]*b)]};function jx(a){this.l=a.matrixIds;kc.call(this,{extent:a.extent,origin:a.origin,origins:a.origins,resolutions:a.resolutions,tileSize:a.tileSize,tileSizes:a.tileSizes,sizes:a.sizes})}u(jx,kc);jx.prototype.o=function(){return this.l};
function kx(a,b,c){var d=[],e=[],f=[],g=[],h=[],l=void 0!==c?c:[];c=Tb(a.SupportedCRS.replace(/urn:ogc:def:crs:(\w+):(.*:)?(\w+)$/,"$1:$3"));var m=c.uc(),n="ne"==c.b.substr(0,2);a.TileMatrix.sort(function(a,b){return b.ScaleDenominator-a.ScaleDenominator});a.TileMatrix.forEach(function(a){var b;0<l.length?b=ia(l,function(b){return a.Identifier==b.TileMatrix}):b=!0;if(b){e.push(a.Identifier);b=2.8E-4*a.ScaleDenominator/m;var c=a.TileWidth,p=a.TileHeight;n?f.push([a.TopLeftCorner[1],a.TopLeftCorner[0]]):
f.push(a.TopLeftCorner);d.push(b);g.push(c==p?c:[c,p]);h.push([a.MatrixWidth,-a.MatrixHeight])}});return new jx({extent:b,origins:f,resolutions:d,matrixIds:e,tileSizes:g,sizes:h})};function Y(a){function b(a){a="KVP"==d?yw(a,f):a.replace(/\{(\w+?)\}/g,function(a,b){return b.toLowerCase()in f?f[b.toLowerCase()]:a});return function(b){if(b){var c={TileMatrix:e.l[b[0]],TileCol:b[1],TileRow:-b[2]-1};qb(c,g);b=a;return b="KVP"==d?yw(b,c):b.replace(/\{(\w+?)\}/g,function(a,b){return c[b]})}}}this.ea=void 0!==a.version?a.version:"1.0.0";this.v=void 0!==a.format?a.format:"image/jpeg";this.i=a.dimensions?a.dimensions:{};this.A=a.layer;this.o=a.matrixSet;this.I=a.style;var c=a.urls;void 0===
c&&void 0!==a.url&&(c=fw(a.url));var d=this.T=void 0!==a.requestEncoding?a.requestEncoding:"KVP",e=a.tileGrid,f={layer:this.A,style:this.I,tilematrixset:this.o};"KVP"==d&&qb(f,{Service:"WMTS",Request:"GetTile",Version:this.ea,Format:this.v});var g=this.i,h=c&&0<c.length?dw(c.map(b)):ew;W.call(this,{attributions:a.attributions,cacheSize:a.cacheSize,crossOrigin:a.crossOrigin,logo:a.logo,projection:a.projection,reprojectionErrorThreshold:a.reprojectionErrorThreshold,tileClass:a.tileClass,tileGrid:e,
tileLoadFunction:a.tileLoadFunction,tilePixelRatio:a.tilePixelRatio,tileUrlFunction:h,urls:c,wrapX:void 0!==a.wrapX?a.wrapX:!1});jw(this,lx(this))}u(Y,W);k=Y.prototype;k.Ik=function(){return this.i};k.yo=function(){return this.v};k.zo=function(){return this.A};k.Vk=function(){return this.o};k.fl=function(){return this.T};k.Ao=function(){return this.I};k.ml=function(){return this.ea};function lx(a){var b=0,c=[],d;for(d in a.i)c[b++]=d+"-"+a.i[d];return c.join("/")}
k.jq=function(a){qb(this.i,a);jw(this,lx(this))};function mx(a){a=a||{};var b=a.size,c=b[0],d=b[1],e=[],f=256;switch(void 0!==a.tierSizeCalculation?a.tierSizeCalculation:nx){case nx:for(;c>f||d>f;)e.push([Math.ceil(c/f),Math.ceil(d/f)]),f+=f;break;case ox:for(;c>f||d>f;)e.push([Math.ceil(c/f),Math.ceil(d/f)]),c>>=1,d>>=1;break;default:sa(!1,53)}e.push([1,1]);e.reverse();for(var f=[1],g=[0],d=1,c=e.length;d<c;d++)f.push(1<<d),g.push(e[d-1][0]*e[d-1][1]+g[d-1]);f.reverse();b=[0,-b[1],b[0],0];b=new kc({extent:b,origin:fb(b),resolutions:f});(f=a.url)&&
-1==f.indexOf("{TileGroup}")&&(f+="{TileGroup}/{z}-{x}-{y}.jpg");f=fw(f);f=dw(f.map(function(a){return function(b){if(b){var c=b[0],d=b[1];b=-b[2]-1;var f={z:c,x:d,y:b,TileGroup:"TileGroup"+((d+b*e[c][0]+g[c])/256|0)};return a.replace(/\{(\w+?)\}/g,function(a,b){return f[b]})}}}));W.call(this,{attributions:a.attributions,cacheSize:a.cacheSize,crossOrigin:a.crossOrigin,logo:a.logo,projection:a.projection,reprojectionErrorThreshold:a.reprojectionErrorThreshold,tileClass:px,tileGrid:b,tileUrlFunction:f})}
u(mx,W);function px(a,b,c,d,e){Ks.call(this,a,b,c,d,e);this.g=null}u(px,Ks);px.prototype.Y=function(){if(this.g)return this.g;var a=Ks.prototype.Y.call(this);if(2==this.state){if(256==a.width&&256==a.height)return this.g=a;var b=hd(256,256);b.drawImage(a,0,0);return this.g=b.canvas}return a};var nx="default",ox="truncated";function qx(a,b){this.b=b;this.a=[{x:0,y:0,width:a,height:a}];this.c={};this.g=hd(a,a);this.i=this.g.canvas}qx.prototype.get=function(a){return this.c[a]||null};
qx.prototype.add=function(a,b,c,d,e){var f,g,h;g=0;for(h=this.a.length;g<h;++g)if(f=this.a[g],f.width>=b+this.b&&f.height>=c+this.b)return h={offsetX:f.x+this.b,offsetY:f.y+this.b,image:this.i},this.c[a]=h,d.call(e,this.g,f.x+this.b,f.y+this.b),a=g,b+=this.b,d=c+this.b,f.width-b>f.height-d?(c={x:f.x+b,y:f.y,width:f.width-b,height:f.height},b={x:f.x,y:f.y+d,width:b,height:f.height-d},rx(this,a,c,b)):(c={x:f.x+b,y:f.y,width:f.width-b,height:d},b={x:f.x,y:f.y+d,width:f.width,height:f.height-d},rx(this,
a,c,b)),h;return null};function rx(a,b,c,d){b=[b,1];0<c.width&&0<c.height&&b.push(c);0<d.width&&0<d.height&&b.push(d);a.a.splice.apply(a.a,b)};function sx(a){a=a||{};this.a=void 0!==a.initialSize?a.initialSize:256;this.g=void 0!==a.maxSize?a.maxSize:void 0!==ca?ca:2048;this.b=void 0!==a.space?a.space:1;this.i=[new qx(this.a,this.b)];this.c=this.a;this.f=[new qx(this.c,this.b)]}sx.prototype.add=function(a,b,c,d,e,f){if(b+this.b>this.g||c+this.b>this.g)return null;d=tx(this,!1,a,b,c,d,f);if(!d)return null;a=tx(this,!0,a,b,c,e?e:oa,f);return{offsetX:d.offsetX,offsetY:d.offsetY,image:d.image,Ul:a.image}};
function tx(a,b,c,d,e,f,g){var h=b?a.f:a.i,l,m,n;m=0;for(n=h.length;m<n;++m){l=h[m];if(l=l.add(c,d,e,f,g))return l;l||m!==n-1||(b?(l=Math.min(2*a.c,a.g),a.c=l):(l=Math.min(2*a.a,a.g),a.a=l),l=new qx(l,a.b),h.push(l),++n)}return null};qa.prototype.code=qa.prototype.code;t("ol.Attribution",xc);xc.prototype.getHTML=xc.prototype.g;t("ol.Collection",D);D.prototype.clear=D.prototype.clear;D.prototype.extend=D.prototype.ag;D.prototype.forEach=D.prototype.forEach;D.prototype.getArray=D.prototype.pm;D.prototype.item=D.prototype.item;D.prototype.getLength=D.prototype.fc;D.prototype.insertAt=D.prototype.Ge;D.prototype.pop=D.prototype.pop;D.prototype.push=D.prototype.push;D.prototype.remove=D.prototype.remove;D.prototype.removeAt=D.prototype.Bg;
D.prototype.setAt=D.prototype.Mp;Yc.prototype.element=Yc.prototype.element;t("ol.color.asArray",bd);t("ol.color.asString",dd);t("ol.colorlike.asColorLike",fd);t("ol.control.defaults",vd);t("ol.coordinate.add",Xe);t("ol.coordinate.createStringXY",function(a){return function(b){return hf(b,a)}});t("ol.coordinate.format",$e);t("ol.coordinate.rotate",cf);t("ol.coordinate.toStringHDMS",function(a,b){return a?Ze(a[1],"NS",b)+" "+Ze(a[0],"EW",b):""});t("ol.coordinate.toStringXY",hf);
t("ol.DeviceOrientation",Rk);Rk.prototype.getAlpha=Rk.prototype.Bk;Rk.prototype.getBeta=Rk.prototype.Ek;Rk.prototype.getGamma=Rk.prototype.Kk;Rk.prototype.getHeading=Rk.prototype.qm;Rk.prototype.getTracking=Rk.prototype.Mh;Rk.prototype.setTracking=Rk.prototype.bg;t("ol.easing.easeIn",od);t("ol.easing.easeOut",pd);t("ol.easing.inAndOut",qd);t("ol.easing.linear",rd);t("ol.easing.upAndDown",function(a){return.5>a?qd(2*a):1-qd(2*(a-.5))});t("ol.extent.boundingExtent",Ia);t("ol.extent.buffer",Ma);
t("ol.extent.containsCoordinate",Qa);t("ol.extent.containsExtent",Ua);t("ol.extent.containsXY",Sa);t("ol.extent.createEmpty",Ja);t("ol.extent.equals",$a);t("ol.extent.extend",ab);t("ol.extent.getBottomLeft",cb);t("ol.extent.getBottomRight",db);t("ol.extent.getCenter",kb);t("ol.extent.getHeight",jb);t("ol.extent.getIntersection",mb);t("ol.extent.getSize",function(a){return[a[2]-a[0],a[3]-a[1]]});t("ol.extent.getTopLeft",fb);t("ol.extent.getTopRight",eb);t("ol.extent.getWidth",ib);
t("ol.extent.intersects",nb);t("ol.extent.isEmpty",hb);t("ol.extent.applyTransform",pb);t("ol.Feature",I);I.prototype.clone=I.prototype.clone;I.prototype.getGeometry=I.prototype.U;I.prototype.getId=I.prototype.sm;I.prototype.getGeometryName=I.prototype.Mk;I.prototype.getStyle=I.prototype.tm;I.prototype.getStyleFunction=I.prototype.Rc;I.prototype.setGeometry=I.prototype.Ta;I.prototype.setStyle=I.prototype.cg;I.prototype.setId=I.prototype.lc;I.prototype.setGeometryName=I.prototype.Yc;
t("ol.featureloader.xhr",Dl);t("ol.Geolocation",us);us.prototype.getAccuracy=us.prototype.zk;us.prototype.getAccuracyGeometry=us.prototype.Ak;us.prototype.getAltitude=us.prototype.Ck;us.prototype.getAltitudeAccuracy=us.prototype.Dk;us.prototype.getHeading=us.prototype.um;us.prototype.getPosition=us.prototype.vm;us.prototype.getProjection=us.prototype.Nh;us.prototype.getSpeed=us.prototype.gl;us.prototype.getTracking=us.prototype.Oh;us.prototype.getTrackingOptions=us.prototype.zh;
us.prototype.setProjection=us.prototype.Ph;us.prototype.setTracking=us.prototype.Je;us.prototype.setTrackingOptions=us.prototype.sj;t("ol.Graticule",As);As.prototype.getMap=As.prototype.ym;As.prototype.getMeridians=As.prototype.Wk;As.prototype.getParallels=As.prototype.cl;As.prototype.setMap=As.prototype.setMap;t("ol.has.DEVICE_PIXEL_RATIO",Td);t("ol.has.CANVAS",Vd);t("ol.has.DEVICE_ORIENTATION",Wd);t("ol.has.GEOLOCATION",Xd);t("ol.has.TOUCH",Yd);t("ol.has.WEBGL",Nd);Gs.prototype.getImage=Gs.prototype.Y;
Gs.prototype.load=Gs.prototype.load;Ks.prototype.getImage=Ks.prototype.Y;t("ol.inherits",u);t("ol.interaction.defaults",oh);t("ol.Kinetic",ig);t("ol.loadingstrategy.all",St);t("ol.loadingstrategy.bbox",function(a){return[a]});t("ol.loadingstrategy.tile",function(a){return function(b,c){var d=a.Qc(c),e=nc(a,b,d),f=[],d=[d,0,0];for(d[1]=e.da;d[1]<=e.ba;++d[1])for(d[2]=e.ga;d[2]<=e.ja;++d[2])f.push(a.Ua(d));return f}});t("ol.Map",H);H.prototype.addControl=H.prototype.gk;H.prototype.addInteraction=H.prototype.hk;
H.prototype.addLayer=H.prototype.$g;H.prototype.addOverlay=H.prototype.ah;H.prototype.forEachFeatureAtPixel=H.prototype.we;H.prototype.forEachLayerAtPixel=H.prototype.Em;H.prototype.hasFeatureAtPixel=H.prototype.Tl;H.prototype.getEventCoordinate=H.prototype.Of;H.prototype.getEventPixel=H.prototype.xe;H.prototype.getTarget=H.prototype.Wf;H.prototype.getTargetElement=H.prototype.vc;H.prototype.getCoordinateFromPixel=H.prototype.Xa;H.prototype.getControls=H.prototype.Hk;H.prototype.getOverlays=H.prototype.al;
H.prototype.getOverlayById=H.prototype.$k;H.prototype.getInteractions=H.prototype.Nk;H.prototype.getLayerGroup=H.prototype.Mc;H.prototype.getLayers=H.prototype.Qh;H.prototype.getPixelFromCoordinate=H.prototype.Ka;H.prototype.getSize=H.prototype.Nb;H.prototype.getView=H.prototype.$;H.prototype.getViewport=H.prototype.nl;H.prototype.renderSync=H.prototype.Jp;H.prototype.render=H.prototype.render;H.prototype.removeControl=H.prototype.Cp;H.prototype.removeInteraction=H.prototype.Dp;
H.prototype.removeLayer=H.prototype.Fp;H.prototype.removeOverlay=H.prototype.Gp;H.prototype.setLayerGroup=H.prototype.lj;H.prototype.setSize=H.prototype.Ig;H.prototype.setTarget=H.prototype.Ke;H.prototype.setView=H.prototype.Yp;H.prototype.updateSize=H.prototype.Cd;Hd.prototype.originalEvent=Hd.prototype.originalEvent;Hd.prototype.pixel=Hd.prototype.pixel;Hd.prototype.coordinate=Hd.prototype.coordinate;Hd.prototype.dragging=Hd.prototype.dragging;Gd.prototype.map=Gd.prototype.map;
Gd.prototype.frameState=Gd.prototype.frameState;t("ol.Object",Qc);Qc.prototype.get=Qc.prototype.get;Qc.prototype.getKeys=Qc.prototype.P;Qc.prototype.getProperties=Qc.prototype.M;Qc.prototype.set=Qc.prototype.set;Qc.prototype.setProperties=Qc.prototype.H;Qc.prototype.unset=Qc.prototype.R;Uc.prototype.key=Uc.prototype.key;Uc.prototype.oldValue=Uc.prototype.oldValue;t("ol.Observable",Pc);t("ol.Observable.unByKey",function(a){if(Array.isArray(a))for(var b=0,c=a.length;b<c;++b)Bc(a[b]);else Bc(a)});
Pc.prototype.changed=Pc.prototype.s;Pc.prototype.dispatchEvent=Pc.prototype.b;Pc.prototype.getRevision=Pc.prototype.L;Pc.prototype.on=Pc.prototype.J;Pc.prototype.once=Pc.prototype.once;Pc.prototype.un=Pc.prototype.K;t("ol.Overlay",sk);sk.prototype.getElement=sk.prototype.Rd;sk.prototype.getId=sk.prototype.Fm;sk.prototype.getMap=sk.prototype.Le;sk.prototype.getOffset=sk.prototype.wh;sk.prototype.getPosition=sk.prototype.Rh;sk.prototype.getPositioning=sk.prototype.xh;sk.prototype.setElement=sk.prototype.gj;
sk.prototype.setMap=sk.prototype.setMap;sk.prototype.setOffset=sk.prototype.nj;sk.prototype.setPosition=sk.prototype.Me;sk.prototype.setPositioning=sk.prototype.qj;t("ol.proj.METERS_PER_UNIT",xb);t("ol.proj.setProj4",function(a){yb=a});t("ol.proj.getPointResolution",Rb);t("ol.proj.addEquivalentProjections",Ub);t("ol.proj.addProjection",Yb);t("ol.proj.addCoordinateTransforms",$b);t("ol.proj.fromLonLat",function(a,b){return fc(a,"EPSG:4326",void 0!==b?b:"EPSG:3857")});
t("ol.proj.toLonLat",function(a,b){return fc(a,void 0!==b?b:"EPSG:3857","EPSG:4326")});t("ol.proj.get",Tb);t("ol.proj.equivalent",bc);t("ol.proj.getTransform",dc);t("ol.proj.transform",fc);t("ol.proj.transformExtent",gc);t("ol.render.toContext",function(a,b){var c=a.canvas,d=b?b:{},e=d.pixelRatio||Td;if(d=d.size)c.width=d[0]*e,c.height=d[1]*e,c.style.width=d[0]+"px",c.style.height=d[1]+"px";c=[0,0,c.width,c.height];d=Fh(yh(),e,e);return new Uh(a,e,c,d,0)});t("ol.size.toSize",Ha);t("ol.Sphere",ub);
ub.prototype.geodesicArea=ub.prototype.a;ub.prototype.haversineDistance=ub.prototype.b;Is.prototype.getTileCoord=Is.prototype.i;Is.prototype.load=Is.prototype.load;t("ol.tilegrid.createXYZ",wc);gx.prototype.getFormat=gx.prototype.Gm;gx.prototype.setFeatures=gx.prototype.hj;gx.prototype.setProjection=gx.prototype.dg;gx.prototype.setLoader=gx.prototype.mj;t("ol.View",G);G.prototype.animate=G.prototype.animate;G.prototype.getAnimating=G.prototype.Kc;G.prototype.cancelAnimations=G.prototype.kd;
G.prototype.constrainCenter=G.prototype.Gc;G.prototype.constrainResolution=G.prototype.constrainResolution;G.prototype.constrainRotation=G.prototype.constrainRotation;G.prototype.getCenter=G.prototype.za;G.prototype.calculateExtent=G.prototype.hd;G.prototype.getMaxResolution=G.prototype.Hm;G.prototype.getMinResolution=G.prototype.Jm;G.prototype.getMaxZoom=G.prototype.Im;G.prototype.setMaxZoom=G.prototype.Up;G.prototype.getMinZoom=G.prototype.Km;G.prototype.setMinZoom=G.prototype.Vp;
G.prototype.getProjection=G.prototype.Lm;G.prototype.getResolution=G.prototype.Ra;G.prototype.getResolutions=G.prototype.Mm;G.prototype.getRotation=G.prototype.Sa;G.prototype.getZoom=G.prototype.Ah;G.prototype.getZoomForResolution=G.prototype.Be;G.prototype.fit=G.prototype.Mf;G.prototype.centerOn=G.prototype.qk;G.prototype.rotate=G.prototype.rotate;G.prototype.setCenter=G.prototype.lb;G.prototype.setResolution=G.prototype.$c;G.prototype.setRotation=G.prototype.Ne;G.prototype.setZoom=G.prototype.aq;
t("ol.xml.getAllTextContent",ll);t("ol.xml.parse",ql);Li.prototype.getGL=Li.prototype.Mo;Li.prototype.useProgram=Li.prototype.Vc;t("ol.tilegrid.TileGrid",kc);kc.prototype.forEachTileCoord=kc.prototype.mh;kc.prototype.getMaxZoom=kc.prototype.Ni;kc.prototype.getMinZoom=kc.prototype.Oi;kc.prototype.getOrigin=kc.prototype.Uc;kc.prototype.getResolution=kc.prototype.La;kc.prototype.getResolutions=kc.prototype.Pi;kc.prototype.getTileCoordExtent=kc.prototype.Ua;
kc.prototype.getTileCoordForCoordAndResolution=kc.prototype.Ae;kc.prototype.getTileCoordForCoordAndZ=kc.prototype.Xf;kc.prototype.getTileSize=kc.prototype.eb;kc.prototype.getZForResolution=kc.prototype.Qc;t("ol.tilegrid.WMTS",jx);jx.prototype.getMatrixIds=jx.prototype.o;t("ol.tilegrid.WMTS.createFromCapabilitiesMatrixSet",kx);t("ol.style.AtlasManager",sx);t("ol.style.Circle",$k);$k.prototype.setRadius=$k.prototype.Zc;t("ol.style.Fill",al);al.prototype.clone=al.prototype.clone;
al.prototype.getColor=al.prototype.g;al.prototype.setColor=al.prototype.c;t("ol.style.Icon",co);co.prototype.clone=co.prototype.clone;co.prototype.getAnchor=co.prototype.Jc;co.prototype.getColor=co.prototype.Bo;co.prototype.getImage=co.prototype.Y;co.prototype.getOrigin=co.prototype.Tc;co.prototype.getSrc=co.prototype.Co;co.prototype.getSize=co.prototype.kc;co.prototype.load=co.prototype.load;t("ol.style.Image",Xk);Xk.prototype.getOpacity=Xk.prototype.Ye;Xk.prototype.getRotateWithView=Xk.prototype.Ze;
Xk.prototype.getRotation=Xk.prototype.$e;Xk.prototype.getScale=Xk.prototype.af;Xk.prototype.getSnapToPixel=Xk.prototype.ze;Xk.prototype.setOpacity=Xk.prototype.vd;Xk.prototype.setRotation=Xk.prototype.bf;Xk.prototype.setScale=Xk.prototype.wd;t("ol.style.RegularShape",Yk);Yk.prototype.clone=Yk.prototype.clone;Yk.prototype.getAnchor=Yk.prototype.Jc;Yk.prototype.getAngle=Yk.prototype.Ji;Yk.prototype.getFill=Yk.prototype.Ca;Yk.prototype.getImage=Yk.prototype.Y;Yk.prototype.getOrigin=Yk.prototype.Tc;
Yk.prototype.getPoints=Yk.prototype.Ki;Yk.prototype.getRadius=Yk.prototype.Li;Yk.prototype.getRadius2=Yk.prototype.yh;Yk.prototype.getSize=Yk.prototype.kc;Yk.prototype.getStroke=Yk.prototype.Da;t("ol.style.Stroke",tj);tj.prototype.clone=tj.prototype.clone;tj.prototype.getColor=tj.prototype.Do;tj.prototype.getLineCap=tj.prototype.Qk;tj.prototype.getLineDash=tj.prototype.Eo;tj.prototype.getLineDashOffset=tj.prototype.Rk;tj.prototype.getLineJoin=tj.prototype.Sk;tj.prototype.getMiterLimit=tj.prototype.Xk;
tj.prototype.getWidth=tj.prototype.Fo;tj.prototype.setColor=tj.prototype.Go;tj.prototype.setLineCap=tj.prototype.Rp;tj.prototype.setLineDash=tj.prototype.setLineDash;tj.prototype.setLineDashOffset=tj.prototype.Sp;tj.prototype.setLineJoin=tj.prototype.Tp;tj.prototype.setMiterLimit=tj.prototype.Wp;tj.prototype.setWidth=tj.prototype.Zp;t("ol.style.Style",bl);bl.prototype.clone=bl.prototype.clone;bl.prototype.getGeometry=bl.prototype.U;bl.prototype.getGeometryFunction=bl.prototype.Lk;
bl.prototype.getFill=bl.prototype.Ca;bl.prototype.setFill=bl.prototype.mf;bl.prototype.getImage=bl.prototype.Y;bl.prototype.setImage=bl.prototype.Hg;bl.prototype.getStroke=bl.prototype.Da;bl.prototype.setStroke=bl.prototype.nf;bl.prototype.getText=bl.prototype.Oa;bl.prototype.setText=bl.prototype.pf;bl.prototype.getZIndex=bl.prototype.Aa;bl.prototype.setGeometry=bl.prototype.Ta;bl.prototype.setZIndex=bl.prototype.Xb;t("ol.style.Text",eo);eo.prototype.clone=eo.prototype.clone;
eo.prototype.getFont=eo.prototype.Jk;eo.prototype.getOffsetX=eo.prototype.Yk;eo.prototype.getOffsetY=eo.prototype.Zk;eo.prototype.getFill=eo.prototype.Ca;eo.prototype.getRotateWithView=eo.prototype.Ho;eo.prototype.getRotation=eo.prototype.Io;eo.prototype.getScale=eo.prototype.Jo;eo.prototype.getStroke=eo.prototype.Da;eo.prototype.getText=eo.prototype.Oa;eo.prototype.getTextAlign=eo.prototype.il;eo.prototype.getTextBaseline=eo.prototype.jl;eo.prototype.setFont=eo.prototype.ij;
eo.prototype.setOffsetX=eo.prototype.oj;eo.prototype.setOffsetY=eo.prototype.pj;eo.prototype.setFill=eo.prototype.mf;eo.prototype.setRotation=eo.prototype.Ko;eo.prototype.setScale=eo.prototype.Mi;eo.prototype.setStroke=eo.prototype.nf;eo.prototype.setText=eo.prototype.pf;eo.prototype.setTextAlign=eo.prototype.rj;eo.prototype.setTextBaseline=eo.prototype.Xp;t("ol.source.BingMaps",qw);t("ol.source.BingMaps.TOS_ATTRIBUTION",rw);qw.prototype.getApiKey=qw.prototype.T;qw.prototype.getImagerySet=qw.prototype.ea;
t("ol.source.CartoDB",tw);tw.prototype.getConfig=tw.prototype.Gk;tw.prototype.updateConfig=tw.prototype.iq;tw.prototype.setConfig=tw.prototype.Np;t("ol.source.Cluster",X);X.prototype.getDistance=X.prototype.Qn;X.prototype.getSource=X.prototype.Rn;X.prototype.setDistance=X.prototype.Op;t("ol.source.Image",zv);Bv.prototype.image=Bv.prototype.image;t("ol.source.ImageArcGISRest",zw);zw.prototype.getParams=zw.prototype.Tn;zw.prototype.getImageLoadFunction=zw.prototype.Sn;zw.prototype.getUrl=zw.prototype.Un;
zw.prototype.setImageLoadFunction=zw.prototype.Vn;zw.prototype.setUrl=zw.prototype.Wn;zw.prototype.updateParams=zw.prototype.Xn;t("ol.source.ImageCanvas",Gv);t("ol.source.ImageMapGuide",Aw);Aw.prototype.getParams=Aw.prototype.Zn;Aw.prototype.getImageLoadFunction=Aw.prototype.Yn;Aw.prototype.updateParams=Aw.prototype.ao;Aw.prototype.setImageLoadFunction=Aw.prototype.$n;t("ol.source.ImageStatic",Bw);t("ol.source.ImageVector",Hv);Hv.prototype.getSource=Hv.prototype.bo;Hv.prototype.getStyle=Hv.prototype.co;
Hv.prototype.getStyleFunction=Hv.prototype.eo;Hv.prototype.setStyle=Hv.prototype.Bi;t("ol.source.ImageWMS",Cw);Cw.prototype.getGetFeatureInfoUrl=Cw.prototype.io;Cw.prototype.getParams=Cw.prototype.ko;Cw.prototype.getImageLoadFunction=Cw.prototype.jo;Cw.prototype.getUrl=Cw.prototype.lo;Cw.prototype.setImageLoadFunction=Cw.prototype.mo;Cw.prototype.setUrl=Cw.prototype.no;Cw.prototype.updateParams=Cw.prototype.oo;t("ol.source.OSM",Gw);t("ol.source.OSM.ATTRIBUTION",Hw);t("ol.source.Raster",Iw);
Iw.prototype.setOperation=Iw.prototype.u;Mw.prototype.extent=Mw.prototype.extent;Mw.prototype.resolution=Mw.prototype.resolution;Mw.prototype.data=Mw.prototype.data;t("ol.source.Source",Tt);Tt.prototype.getAttributions=Tt.prototype.xa;Tt.prototype.getLogo=Tt.prototype.wa;Tt.prototype.getProjection=Tt.prototype.ya;Tt.prototype.getState=Tt.prototype.V;Tt.prototype.refresh=Tt.prototype.va;Tt.prototype.setAttributions=Tt.prototype.ua;t("ol.source.Stamen",Pw);t("ol.source.Tile",iw);
iw.prototype.getTileGrid=iw.prototype.ab;lw.prototype.tile=lw.prototype.tile;t("ol.source.TileArcGISRest",Tw);Tw.prototype.getParams=Tw.prototype.v;Tw.prototype.updateParams=Tw.prototype.A;t("ol.source.TileDebug",Vw);t("ol.source.TileImage",W);W.prototype.setRenderReprojectionEdges=W.prototype.Ob;W.prototype.setTileGridForProjection=W.prototype.Pb;t("ol.source.TileJSON",Xw);Xw.prototype.getTileJSON=Xw.prototype.kl;t("ol.source.TileUTFGrid",Yw);Yw.prototype.getTemplate=Yw.prototype.hl;
Yw.prototype.forDataAtCoordinateAndResolution=Yw.prototype.vk;t("ol.source.TileWMS",bx);bx.prototype.getGetFeatureInfoUrl=bx.prototype.vo;bx.prototype.getParams=bx.prototype.wo;bx.prototype.updateParams=bx.prototype.xo;mw.prototype.getTileLoadFunction=mw.prototype.ob;mw.prototype.getTileUrlFunction=mw.prototype.qb;mw.prototype.getUrls=mw.prototype.rb;mw.prototype.setTileLoadFunction=mw.prototype.wb;mw.prototype.setTileUrlFunction=mw.prototype.bb;mw.prototype.setUrl=mw.prototype.ib;
mw.prototype.setUrls=mw.prototype.cb;t("ol.source.Vector",T);T.prototype.addFeature=T.prototype.zb;T.prototype.addFeatures=T.prototype.gd;T.prototype.clear=T.prototype.clear;T.prototype.forEachFeature=T.prototype.kh;T.prototype.forEachFeatureInExtent=T.prototype.bc;T.prototype.forEachFeatureIntersectingExtent=T.prototype.lh;T.prototype.getFeaturesCollection=T.prototype.th;T.prototype.getFeatures=T.prototype.We;T.prototype.getFeaturesAtCoordinate=T.prototype.sh;T.prototype.getFeaturesInExtent=T.prototype.Pf;
T.prototype.getClosestFeatureToCoordinate=T.prototype.oh;T.prototype.getExtent=T.prototype.D;T.prototype.getFeatureById=T.prototype.rh;T.prototype.getFormat=T.prototype.Gi;T.prototype.getUrl=T.prototype.Hi;T.prototype.removeFeature=T.prototype.Db;$t.prototype.feature=$t.prototype.feature;t("ol.source.VectorTile",ix);t("ol.source.WMTS",Y);Y.prototype.getDimensions=Y.prototype.Ik;Y.prototype.getFormat=Y.prototype.yo;Y.prototype.getLayer=Y.prototype.zo;Y.prototype.getMatrixSet=Y.prototype.Vk;
Y.prototype.getRequestEncoding=Y.prototype.fl;Y.prototype.getStyle=Y.prototype.Ao;Y.prototype.getVersion=Y.prototype.ml;Y.prototype.updateDimensions=Y.prototype.jq;
t("ol.source.WMTS.optionsFromCapabilities",function(a,b){var c=ia(a.Contents.Layer,function(a){return a.Identifier==b.layer});if(null===c)return null;var d=a.Contents.TileMatrixSet,e,f,g;e=1<c.TileMatrixSetLink.length?"projection"in b?ma(c.TileMatrixSetLink,function(a){var c=ia(d,function(b){return b.Identifier==a.TileMatrixSet}).SupportedCRS.replace(/urn:ogc:def:crs:(\w+):(.*:)?(\w+)$/,"$1:$3"),e=Tb(c),f=Tb(b.projection);return e&&f?bc(e,f):c==b.projection}):ma(c.TileMatrixSetLink,function(a){return a.TileMatrixSet==
b.matrixSet}):0;0>e&&(e=0);f=c.TileMatrixSetLink[e].TileMatrixSet;g=c.TileMatrixSetLink[e].TileMatrixSetLimits;var h=c.Format[0];"format"in b&&(h=b.format);e=ma(c.Style,function(a){return"style"in b?a.Title==b.style:a.isDefault});0>e&&(e=0);e=c.Style[e].Identifier;var l={};"Dimension"in c&&c.Dimension.forEach(function(a){var b=a.Identifier,c=a.Default;void 0===c&&(c=a.Value[0]);l[b]=c});var m=ia(a.Contents.TileMatrixSet,function(a){return a.Identifier==f}),n;n="projection"in b?Tb(b.projection):Tb(m.SupportedCRS.replace(/urn:ogc:def:crs:(\w+):(.*:)?(\w+)$/,
"$1:$3"));var p=c.WGS84BoundingBox,q,r;void 0!==p&&(r=Tb("EPSG:4326").D(),r=p[0]==r[0]&&p[2]==r[2],q=gc(p,"EPSG:4326",n),(p=n.D())&&(Ua(p,q)||(q=void 0)));g=kx(m,q,g);var v=[],m=b.requestEncoding,m=void 0!==m?m:"";if("OperationsMetadata"in a&&"GetTile"in a.OperationsMetadata){q=a.OperationsMetadata.GetTile.DCP.HTTP.Get;for(var p=0,x=q.length;p<x;++p){var y=ia(q[p].Constraint,function(a){return"GetEncoding"==a.name}).AllowedValues.Value;""===m&&(m=y[0]);if("KVP"===m)fa(y,"KVP")&&v.push(q[p].href);
else break}}v.length||(m="REST",c.ResourceURL.forEach(function(a){"tile"===a.resourceType&&(h=a.format,v.push(a.template))}));return{urls:v,layer:b.layer,matrixSet:f,format:h,projection:n,requestEncoding:m,tileGrid:g,style:e,dimensions:l,wrapX:r,crossOrigin:b.crossOrigin}});t("ol.source.XYZ",sw);t("ol.source.Zoomify",mx);Oh.prototype.vectorContext=Oh.prototype.vectorContext;Oh.prototype.frameState=Oh.prototype.frameState;Oh.prototype.context=Oh.prototype.context;Oh.prototype.glContext=Oh.prototype.glContext;
jq.prototype.get=jq.prototype.get;jq.prototype.getExtent=jq.prototype.D;jq.prototype.getGeometry=jq.prototype.U;jq.prototype.getProperties=jq.prototype.Nn;jq.prototype.getType=jq.prototype.S;t("ol.render.VectorContext",Th);kk.prototype.setStyle=kk.prototype.td;kk.prototype.drawGeometry=kk.prototype.oc;kk.prototype.drawFeature=kk.prototype.te;Uh.prototype.drawCircle=Uh.prototype.ac;Uh.prototype.setStyle=Uh.prototype.td;Uh.prototype.drawGeometry=Uh.prototype.oc;Uh.prototype.drawFeature=Uh.prototype.te;
t("ol.proj.common.add",hc);t("ol.proj.Projection",zb);zb.prototype.getCode=zb.prototype.Fk;zb.prototype.getExtent=zb.prototype.D;zb.prototype.getUnits=zb.prototype.Kb;zb.prototype.getMetersPerUnit=zb.prototype.uc;zb.prototype.getWorldExtent=zb.prototype.ol;zb.prototype.isGlobal=zb.prototype.Zl;zb.prototype.setGlobal=zb.prototype.Qp;zb.prototype.setExtent=zb.prototype.Mn;zb.prototype.setWorldExtent=zb.prototype.$p;zb.prototype.setGetPointResolution=zb.prototype.Pp;
t("ol.proj.Units.METERS_PER_UNIT",xb);t("ol.layer.Base",ph);ph.prototype.getExtent=ph.prototype.D;ph.prototype.getMaxResolution=ph.prototype.hc;ph.prototype.getMinResolution=ph.prototype.ic;ph.prototype.getOpacity=ph.prototype.jc;ph.prototype.getVisible=ph.prototype.Lb;ph.prototype.getZIndex=ph.prototype.Aa;ph.prototype.setExtent=ph.prototype.xc;ph.prototype.setMaxResolution=ph.prototype.Cc;ph.prototype.setMinResolution=ph.prototype.Dc;ph.prototype.setOpacity=ph.prototype.yc;
ph.prototype.setVisible=ph.prototype.zc;ph.prototype.setZIndex=ph.prototype.Xb;t("ol.layer.Group",rh);rh.prototype.getLayers=rh.prototype.sd;rh.prototype.setLayers=rh.prototype.pi;t("ol.layer.Heatmap",U);U.prototype.getBlur=U.prototype.nh;U.prototype.getGradient=U.prototype.uh;U.prototype.getRadius=U.prototype.ri;U.prototype.setBlur=U.prototype.ej;U.prototype.setGradient=U.prototype.kj;U.prototype.setRadius=U.prototype.Zc;t("ol.layer.Image",Mv);Mv.prototype.getSource=Mv.prototype.ka;
t("ol.layer.Layer",th);th.prototype.getSource=th.prototype.ka;th.prototype.setMap=th.prototype.setMap;th.prototype.setSource=th.prototype.ad;t("ol.layer.Tile",Vv);Vv.prototype.getPreload=Vv.prototype.Sd;Vv.prototype.getSource=Vv.prototype.ka;Vv.prototype.setPreload=Vv.prototype.si;Vv.prototype.getUseInterimTilesOnError=Vv.prototype.Wd;Vv.prototype.setUseInterimTilesOnError=Vv.prototype.ti;t("ol.layer.Vector",S);S.prototype.getSource=S.prototype.ka;S.prototype.getStyle=S.prototype.C;
S.prototype.getStyleFunction=S.prototype.G;S.prototype.setStyle=S.prototype.f;t("ol.layer.VectorTile",V);V.prototype.getPreload=V.prototype.Sd;V.prototype.getUseInterimTilesOnError=V.prototype.Wd;V.prototype.setPreload=V.prototype.ui;V.prototype.setUseInterimTilesOnError=V.prototype.vi;t("ol.interaction.DoubleClickZoom",og);t("ol.interaction.DoubleClickZoom.handleEvent",pg);t("ol.interaction.DragAndDrop",Ms);t("ol.interaction.DragAndDrop.handleEvent",jf);Ps.prototype.features=Ps.prototype.features;
Ps.prototype.file=Ps.prototype.file;Ps.prototype.projection=Ps.prototype.projection;t("ol.interaction.DragBox",Og);Og.prototype.getGeometry=Og.prototype.U;Tg.prototype.coordinate=Tg.prototype.coordinate;Tg.prototype.mapBrowserEvent=Tg.prototype.mapBrowserEvent;t("ol.interaction.DragPan",Dg);t("ol.interaction.DragRotate",Hg);t("ol.interaction.DragRotateAndZoom",Rs);t("ol.interaction.DragZoom",Xg);t("ol.interaction.Draw",cu);t("ol.interaction.Draw.handleEvent",eu);cu.prototype.removeLastPoint=cu.prototype.Ep;
cu.prototype.finishDrawing=cu.prototype.Qd;cu.prototype.extend=cu.prototype.nn;t("ol.interaction.Draw.createRegularPolygon",function(a,b){return function(c,d){var e=c[0],f=c[1],g=Math.sqrt(ef(e,f)),h=d?d:Wf(new vs(e),a);Xf(h,e,g,b?b:Math.atan((f[1]-e[1])/(f[0]-e[0])));return h}});t("ol.interaction.Draw.createBox",function(){return function(a,b){var c=Ia(a),d=b||new F(null);d.pa([[cb(c),db(c),eb(c),fb(c),cb(c)]]);return d}});su.prototype.feature=su.prototype.feature;t("ol.interaction.Extent",tu);
tu.prototype.getExtent=tu.prototype.D;tu.prototype.setExtent=tu.prototype.f;Eu.prototype.extent_=Eu.prototype.b;t("ol.interaction.Interaction",kg);kg.prototype.getActive=kg.prototype.c;kg.prototype.getMap=kg.prototype.i;kg.prototype.setActive=kg.prototype.Ia;t("ol.interaction.KeyboardPan",Yg);t("ol.interaction.KeyboardPan.handleEvent",Zg);t("ol.interaction.KeyboardZoom",$g);t("ol.interaction.KeyboardZoom.handleEvent",ah);t("ol.interaction.Modify",Gu);t("ol.interaction.Modify.handleEvent",Ju);
Gu.prototype.removePoint=Gu.prototype.cj;Ou.prototype.features=Ou.prototype.features;Ou.prototype.mapBrowserEvent=Ou.prototype.mapBrowserEvent;t("ol.interaction.MouseWheelZoom",bh);t("ol.interaction.MouseWheelZoom.handleEvent",ch);bh.prototype.setMouseAnchor=bh.prototype.T;t("ol.interaction.PinchRotate",fh);t("ol.interaction.PinchZoom",jh);t("ol.interaction.Pointer",Ag);t("ol.interaction.Pointer.handleEvent",Bg);t("ol.interaction.Select",Wu);Wu.prototype.getFeatures=Wu.prototype.zn;
Wu.prototype.getHitTolerance=Wu.prototype.An;Wu.prototype.getLayer=Wu.prototype.Bn;t("ol.interaction.Select.handleEvent",Xu);Wu.prototype.setHitTolerance=Wu.prototype.Dn;Wu.prototype.setMap=Wu.prototype.setMap;Zu.prototype.selected=Zu.prototype.selected;Zu.prototype.deselected=Zu.prototype.deselected;Zu.prototype.mapBrowserEvent=Zu.prototype.mapBrowserEvent;t("ol.interaction.Snap",av);av.prototype.addFeature=av.prototype.zb;av.prototype.removeFeature=av.prototype.Db;t("ol.interaction.Translate",ev);
ev.prototype.getHitTolerance=ev.prototype.I;ev.prototype.setHitTolerance=ev.prototype.Z;kv.prototype.features=kv.prototype.features;kv.prototype.coordinate=kv.prototype.coordinate;t("ol.geom.Circle",vs);vs.prototype.clone=vs.prototype.clone;vs.prototype.getCenter=vs.prototype.za;vs.prototype.getRadius=vs.prototype.Yd;vs.prototype.getType=vs.prototype.S;vs.prototype.intersectsExtent=vs.prototype.Ya;vs.prototype.setCenter=vs.prototype.lb;vs.prototype.setCenterAndRadius=vs.prototype.Gg;
vs.prototype.setRadius=vs.prototype.Zc;vs.prototype.transform=vs.prototype.tb;t("ol.geom.Geometry",lf);lf.prototype.getClosestPoint=lf.prototype.Ab;lf.prototype.intersectsCoordinate=lf.prototype.sb;lf.prototype.getExtent=lf.prototype.D;lf.prototype.rotate=lf.prototype.rotate;lf.prototype.scale=lf.prototype.scale;lf.prototype.simplify=lf.prototype.Qb;lf.prototype.transform=lf.prototype.tb;t("ol.geom.GeometryCollection",sm);sm.prototype.clone=sm.prototype.clone;sm.prototype.getGeometries=sm.prototype.Qf;
sm.prototype.getType=sm.prototype.S;sm.prototype.intersectsExtent=sm.prototype.Ya;sm.prototype.setGeometries=sm.prototype.jj;sm.prototype.applyTransform=sm.prototype.Fc;sm.prototype.translate=sm.prototype.translate;t("ol.geom.LinearRing",Gf);Gf.prototype.clone=Gf.prototype.clone;Gf.prototype.getArea=Gf.prototype.jn;Gf.prototype.getCoordinates=Gf.prototype.W;Gf.prototype.getType=Gf.prototype.S;Gf.prototype.setCoordinates=Gf.prototype.pa;t("ol.geom.LineString",N);N.prototype.appendCoordinate=N.prototype.ik;
N.prototype.clone=N.prototype.clone;N.prototype.forEachSegment=N.prototype.yk;N.prototype.getCoordinateAtM=N.prototype.gn;N.prototype.getCoordinates=N.prototype.W;N.prototype.getCoordinateAt=N.prototype.ph;N.prototype.getLength=N.prototype.hn;N.prototype.getType=N.prototype.S;N.prototype.intersectsExtent=N.prototype.Ya;N.prototype.setCoordinates=N.prototype.pa;t("ol.geom.MultiLineString",O);O.prototype.appendLineString=O.prototype.jk;O.prototype.clone=O.prototype.clone;
O.prototype.getCoordinateAtM=O.prototype.kn;O.prototype.getCoordinates=O.prototype.W;O.prototype.getLineString=O.prototype.Tk;O.prototype.getLineStrings=O.prototype.Nc;O.prototype.getType=O.prototype.S;O.prototype.intersectsExtent=O.prototype.Ya;O.prototype.setCoordinates=O.prototype.pa;t("ol.geom.MultiPoint",P);P.prototype.appendPoint=P.prototype.lk;P.prototype.clone=P.prototype.clone;P.prototype.getCoordinates=P.prototype.W;P.prototype.getPoint=P.prototype.dl;P.prototype.getPoints=P.prototype.Zd;
P.prototype.getType=P.prototype.S;P.prototype.intersectsExtent=P.prototype.Ya;P.prototype.setCoordinates=P.prototype.pa;t("ol.geom.MultiPolygon",Q);Q.prototype.appendPolygon=Q.prototype.mk;Q.prototype.clone=Q.prototype.clone;Q.prototype.getArea=Q.prototype.ln;Q.prototype.getCoordinates=Q.prototype.W;Q.prototype.getInteriorPoints=Q.prototype.Pk;Q.prototype.getPolygon=Q.prototype.el;Q.prototype.getPolygons=Q.prototype.md;Q.prototype.getType=Q.prototype.S;Q.prototype.intersectsExtent=Q.prototype.Ya;
Q.prototype.setCoordinates=Q.prototype.pa;t("ol.geom.Point",E);E.prototype.clone=E.prototype.clone;E.prototype.getCoordinates=E.prototype.W;E.prototype.getType=E.prototype.S;E.prototype.intersectsExtent=E.prototype.Ya;E.prototype.setCoordinates=E.prototype.pa;t("ol.geom.Polygon",F);F.prototype.appendLinearRing=F.prototype.kk;F.prototype.clone=F.prototype.clone;F.prototype.getArea=F.prototype.mn;F.prototype.getCoordinates=F.prototype.W;F.prototype.getInteriorPoint=F.prototype.Ok;
F.prototype.getLinearRingCount=F.prototype.Uk;F.prototype.getLinearRing=F.prototype.vh;F.prototype.getLinearRings=F.prototype.Oc;F.prototype.getType=F.prototype.S;F.prototype.intersectsExtent=F.prototype.Ya;F.prototype.setCoordinates=F.prototype.pa;t("ol.geom.Polygon.circular",Uf);t("ol.geom.Polygon.fromExtent",Vf);t("ol.geom.Polygon.fromCircle",Wf);t("ol.geom.SimpleGeometry",of);of.prototype.getFirstCoordinate=of.prototype.cc;of.prototype.getLastCoordinate=of.prototype.dc;
of.prototype.getLayout=of.prototype.ec;of.prototype.applyTransform=of.prototype.Fc;of.prototype.translate=of.prototype.translate;t("ol.format.EsriJSON",Ql);Ql.prototype.readFeature=Ql.prototype.Vb;Ql.prototype.readFeatures=Ql.prototype.Pa;Ql.prototype.readGeometry=Ql.prototype.Xc;Ql.prototype.readProjection=Ql.prototype.jb;Ql.prototype.writeGeometry=Ql.prototype.ed;Ql.prototype.writeGeometryObject=Ql.prototype.ie;Ql.prototype.writeFeature=Ql.prototype.Dd;Ql.prototype.writeFeatureObject=Ql.prototype.dd;
Ql.prototype.writeFeatures=Ql.prototype.Yb;Ql.prototype.writeFeaturesObject=Ql.prototype.ge;t("ol.format.Feature",El);t("ol.format.filter.and",qm);t("ol.format.filter.or",function(a){var b=[null].concat(Array.prototype.slice.call(arguments));return new (Function.prototype.bind.apply(om,b))});t("ol.format.filter.not",function(a){return new mm(a)});t("ol.format.filter.bbox",rm);t("ol.format.filter.intersects",function(a,b,c){return new gm(a,b,c)});
t("ol.format.filter.within",function(a,b,c){return new pm(a,b,c)});t("ol.format.filter.equalTo",function(a,b,c){return new cm(a,b,c)});t("ol.format.filter.notEqualTo",function(a,b,c){return new nm(a,b,c)});t("ol.format.filter.lessThan",function(a,b){return new km(a,b)});t("ol.format.filter.lessThanOrEqualTo",function(a,b){return new lm(a,b)});t("ol.format.filter.greaterThan",function(a,b){return new dm(a,b)});t("ol.format.filter.greaterThanOrEqualTo",function(a,b){return new em(a,b)});
t("ol.format.filter.isNull",function(a){return new jm(a)});t("ol.format.filter.between",function(a,b,c){return new hm(a,b,c)});t("ol.format.filter.like",function(a,b,c,d,e,f){return new im(a,b,c,d,e,f)});t("ol.format.GeoJSON",wm);wm.prototype.readFeature=wm.prototype.Vb;wm.prototype.readFeatures=wm.prototype.Pa;wm.prototype.readGeometry=wm.prototype.Xc;wm.prototype.readProjection=wm.prototype.jb;wm.prototype.writeFeature=wm.prototype.Dd;wm.prototype.writeFeatureObject=wm.prototype.dd;
wm.prototype.writeFeatures=wm.prototype.Yb;wm.prototype.writeFeaturesObject=wm.prototype.ge;wm.prototype.writeGeometry=wm.prototype.ed;wm.prototype.writeGeometryObject=wm.prototype.ie;t("ol.format.GML",Rm);Rm.prototype.writeFeatures=Rm.prototype.Yb;Rm.prototype.writeFeaturesNode=Rm.prototype.Zb;t("ol.format.GML2",$m);t("ol.format.GML3",Rm);Rm.prototype.writeGeometryNode=Rm.prototype.he;Rm.prototype.writeFeatures=Rm.prototype.Yb;Rm.prototype.writeFeaturesNode=Rm.prototype.Zb;
Em.prototype.readFeatures=Em.prototype.Pa;t("ol.format.GPX",ln);ln.prototype.readFeature=ln.prototype.Vb;ln.prototype.readFeatures=ln.prototype.Pa;ln.prototype.readProjection=ln.prototype.jb;ln.prototype.writeFeatures=ln.prototype.Yb;ln.prototype.writeFeaturesNode=ln.prototype.Zb;t("ol.format.IGC",Wn);Wn.prototype.readFeature=Wn.prototype.Vb;Wn.prototype.readFeatures=Wn.prototype.Pa;Wn.prototype.readProjection=Wn.prototype.jb;t("ol.format.KML",fo);fo.prototype.readFeature=fo.prototype.Vb;
fo.prototype.readFeatures=fo.prototype.Pa;fo.prototype.readName=fo.prototype.sp;fo.prototype.readNetworkLinks=fo.prototype.tp;fo.prototype.readRegion=fo.prototype.wp;fo.prototype.readRegionFromNode=fo.prototype.jf;fo.prototype.readProjection=fo.prototype.jb;fo.prototype.writeFeatures=fo.prototype.Yb;fo.prototype.writeFeaturesNode=fo.prototype.Zb;t("ol.format.MVT",kq);kq.prototype.readFeatures=kq.prototype.Pa;kq.prototype.readProjection=kq.prototype.jb;kq.prototype.setLayers=kq.prototype.fn;
t("ol.format.OSMXML",mq);mq.prototype.readFeatures=mq.prototype.Pa;mq.prototype.readProjection=mq.prototype.jb;t("ol.format.Polyline",Mq);t("ol.format.Polyline.encodeDeltas",Nq);t("ol.format.Polyline.decodeDeltas",Pq);t("ol.format.Polyline.encodeFloats",Oq);t("ol.format.Polyline.decodeFloats",Qq);Mq.prototype.readFeature=Mq.prototype.Vb;Mq.prototype.readFeatures=Mq.prototype.Pa;Mq.prototype.readGeometry=Mq.prototype.Xc;Mq.prototype.readProjection=Mq.prototype.jb;Mq.prototype.writeGeometry=Mq.prototype.ed;
t("ol.format.TopoJSON",Rq);Rq.prototype.readFeatures=Rq.prototype.Pa;Rq.prototype.readProjection=Rq.prototype.jb;t("ol.format.WFS",Xq);Xq.prototype.readFeatures=Xq.prototype.Pa;Xq.prototype.readTransactionResponse=Xq.prototype.j;Xq.prototype.readFeatureCollectionMetadata=Xq.prototype.f;t("ol.format.WFS.writeFilter",function(a){var b=kl("http://www.opengis.net/ogc","Filter");Bl({node:b},kr,wl(a.mc),[a],[]);return b});Xq.prototype.writeGetFeature=Xq.prototype.o;Xq.prototype.writeTransaction=Xq.prototype.u;
Xq.prototype.readProjection=Xq.prototype.jb;t("ol.format.WKT",pr);pr.prototype.readFeature=pr.prototype.Vb;pr.prototype.readFeatures=pr.prototype.Pa;pr.prototype.readGeometry=pr.prototype.Xc;pr.prototype.writeFeature=pr.prototype.Dd;pr.prototype.writeFeatures=pr.prototype.Yb;pr.prototype.writeGeometry=pr.prototype.ed;t("ol.format.WMSCapabilities",Ir);Ir.prototype.read=Ir.prototype.read;t("ol.format.WMSGetFeatureInfo",es);es.prototype.readFeatures=es.prototype.Pa;t("ol.format.WMTSCapabilities",fs);
fs.prototype.read=fs.prototype.read;t("ol.format.filter.And",Zl);t("ol.format.filter.Bbox",$l);t("ol.format.filter.Comparison",am);t("ol.format.filter.ComparisonBinary",bm);t("ol.format.filter.EqualTo",cm);t("ol.format.filter.Filter",Xl);t("ol.format.filter.GreaterThan",dm);t("ol.format.filter.GreaterThanOrEqualTo",em);t("ol.format.filter.Intersects",gm);t("ol.format.filter.IsBetween",hm);t("ol.format.filter.IsLike",im);t("ol.format.filter.IsNull",jm);t("ol.format.filter.LessThan",km);
t("ol.format.filter.LessThanOrEqualTo",lm);t("ol.format.filter.Not",mm);t("ol.format.filter.NotEqualTo",nm);t("ol.format.filter.Or",om);t("ol.format.filter.Spatial",fm);t("ol.format.filter.Within",pm);t("ol.events.condition.altKeyOnly",function(a){a=a.originalEvent;return a.altKey&&!(a.metaKey||a.ctrlKey)&&!a.shiftKey});t("ol.events.condition.altShiftKeysOnly",qg);t("ol.events.condition.always",jf);t("ol.events.condition.click",function(a){return"click"==a.type});t("ol.events.condition.never",kf);
t("ol.events.condition.pointerMove",sg);t("ol.events.condition.singleClick",tg);t("ol.events.condition.doubleClick",function(a){return"dblclick"==a.type});t("ol.events.condition.noModifierKeys",vg);t("ol.events.condition.platformModifierKeyOnly",function(a){a=a.originalEvent;return!a.altKey&&(Sd?a.metaKey:a.ctrlKey)&&!a.shiftKey});t("ol.events.condition.shiftKeyOnly",wg);t("ol.events.condition.targetNotEditable",xg);t("ol.events.condition.mouseOnly",yg);t("ol.events.condition.primaryAction",zg);
Lc.prototype.type=Lc.prototype.type;Lc.prototype.target=Lc.prototype.target;Lc.prototype.preventDefault=Lc.prototype.preventDefault;Lc.prototype.stopPropagation=Lc.prototype.stopPropagation;t("ol.control.Attribution",ld);t("ol.control.Attribution.render",md);ld.prototype.getCollapsible=ld.prototype.Om;ld.prototype.setCollapsible=ld.prototype.Rm;ld.prototype.setCollapsed=ld.prototype.Qm;ld.prototype.getCollapsed=ld.prototype.Nm;t("ol.control.Control",kd);kd.prototype.getMap=kd.prototype.f;
kd.prototype.setMap=kd.prototype.setMap;kd.prototype.setTarget=kd.prototype.i;t("ol.control.FullScreen",wd);t("ol.control.MousePosition",Bd);t("ol.control.MousePosition.render",Cd);Bd.prototype.getCoordinateFormat=Bd.prototype.qh;Bd.prototype.getProjection=Bd.prototype.Sh;Bd.prototype.setCoordinateFormat=Bd.prototype.fj;Bd.prototype.setProjection=Bd.prototype.Th;t("ol.control.OverviewMap",Bk);t("ol.control.OverviewMap.render",Ck);Bk.prototype.getCollapsible=Bk.prototype.Um;
Bk.prototype.setCollapsible=Bk.prototype.Xm;Bk.prototype.setCollapsed=Bk.prototype.Wm;Bk.prototype.getCollapsed=Bk.prototype.Tm;Bk.prototype.getOverviewMap=Bk.prototype.bl;t("ol.control.Rotate",sd);t("ol.control.Rotate.render",td);t("ol.control.ScaleLine",Gk);Gk.prototype.getUnits=Gk.prototype.Kb;t("ol.control.ScaleLine.render",Hk);Gk.prototype.setUnits=Gk.prototype.G;t("ol.control.Zoom",ud);t("ol.control.ZoomSlider",Lk);t("ol.control.ZoomSlider.render",Nk);t("ol.control.ZoomToExtent",Qk);
Qc.prototype.changed=Qc.prototype.s;Qc.prototype.dispatchEvent=Qc.prototype.b;Qc.prototype.getRevision=Qc.prototype.L;Qc.prototype.on=Qc.prototype.J;Qc.prototype.once=Qc.prototype.once;Qc.prototype.un=Qc.prototype.K;D.prototype.get=D.prototype.get;D.prototype.getKeys=D.prototype.P;D.prototype.getProperties=D.prototype.M;D.prototype.set=D.prototype.set;D.prototype.setProperties=D.prototype.H;D.prototype.unset=D.prototype.R;D.prototype.changed=D.prototype.s;D.prototype.dispatchEvent=D.prototype.b;
D.prototype.getRevision=D.prototype.L;D.prototype.on=D.prototype.J;D.prototype.once=D.prototype.once;D.prototype.un=D.prototype.K;Yc.prototype.type=Yc.prototype.type;Yc.prototype.target=Yc.prototype.target;Yc.prototype.preventDefault=Yc.prototype.preventDefault;Yc.prototype.stopPropagation=Yc.prototype.stopPropagation;Rk.prototype.get=Rk.prototype.get;Rk.prototype.getKeys=Rk.prototype.P;Rk.prototype.getProperties=Rk.prototype.M;Rk.prototype.set=Rk.prototype.set;Rk.prototype.setProperties=Rk.prototype.H;
Rk.prototype.unset=Rk.prototype.R;Rk.prototype.changed=Rk.prototype.s;Rk.prototype.dispatchEvent=Rk.prototype.b;Rk.prototype.getRevision=Rk.prototype.L;Rk.prototype.on=Rk.prototype.J;Rk.prototype.once=Rk.prototype.once;Rk.prototype.un=Rk.prototype.K;I.prototype.get=I.prototype.get;I.prototype.getKeys=I.prototype.P;I.prototype.getProperties=I.prototype.M;I.prototype.set=I.prototype.set;I.prototype.setProperties=I.prototype.H;I.prototype.unset=I.prototype.R;I.prototype.changed=I.prototype.s;
I.prototype.dispatchEvent=I.prototype.b;I.prototype.getRevision=I.prototype.L;I.prototype.on=I.prototype.J;I.prototype.once=I.prototype.once;I.prototype.un=I.prototype.K;us.prototype.get=us.prototype.get;us.prototype.getKeys=us.prototype.P;us.prototype.getProperties=us.prototype.M;us.prototype.set=us.prototype.set;us.prototype.setProperties=us.prototype.H;us.prototype.unset=us.prototype.R;us.prototype.changed=us.prototype.s;us.prototype.dispatchEvent=us.prototype.b;us.prototype.getRevision=us.prototype.L;
us.prototype.on=us.prototype.J;us.prototype.once=us.prototype.once;us.prototype.un=us.prototype.K;Ks.prototype.getTileCoord=Ks.prototype.i;Ks.prototype.load=Ks.prototype.load;H.prototype.get=H.prototype.get;H.prototype.getKeys=H.prototype.P;H.prototype.getProperties=H.prototype.M;H.prototype.set=H.prototype.set;H.prototype.setProperties=H.prototype.H;H.prototype.unset=H.prototype.R;H.prototype.changed=H.prototype.s;H.prototype.dispatchEvent=H.prototype.b;H.prototype.getRevision=H.prototype.L;
H.prototype.on=H.prototype.J;H.prototype.once=H.prototype.once;H.prototype.un=H.prototype.K;Gd.prototype.type=Gd.prototype.type;Gd.prototype.target=Gd.prototype.target;Gd.prototype.preventDefault=Gd.prototype.preventDefault;Gd.prototype.stopPropagation=Gd.prototype.stopPropagation;Hd.prototype.map=Hd.prototype.map;Hd.prototype.frameState=Hd.prototype.frameState;Hd.prototype.type=Hd.prototype.type;Hd.prototype.target=Hd.prototype.target;Hd.prototype.preventDefault=Hd.prototype.preventDefault;
Hd.prototype.stopPropagation=Hd.prototype.stopPropagation;Kd.prototype.originalEvent=Kd.prototype.originalEvent;Kd.prototype.pixel=Kd.prototype.pixel;Kd.prototype.coordinate=Kd.prototype.coordinate;Kd.prototype.dragging=Kd.prototype.dragging;Kd.prototype.preventDefault=Kd.prototype.preventDefault;Kd.prototype.stopPropagation=Kd.prototype.stopPropagation;Kd.prototype.map=Kd.prototype.map;Kd.prototype.frameState=Kd.prototype.frameState;Kd.prototype.type=Kd.prototype.type;Kd.prototype.target=Kd.prototype.target;
Uc.prototype.type=Uc.prototype.type;Uc.prototype.target=Uc.prototype.target;Uc.prototype.preventDefault=Uc.prototype.preventDefault;Uc.prototype.stopPropagation=Uc.prototype.stopPropagation;sk.prototype.get=sk.prototype.get;sk.prototype.getKeys=sk.prototype.P;sk.prototype.getProperties=sk.prototype.M;sk.prototype.set=sk.prototype.set;sk.prototype.setProperties=sk.prototype.H;sk.prototype.unset=sk.prototype.R;sk.prototype.changed=sk.prototype.s;sk.prototype.dispatchEvent=sk.prototype.b;
sk.prototype.getRevision=sk.prototype.L;sk.prototype.on=sk.prototype.J;sk.prototype.once=sk.prototype.once;sk.prototype.un=sk.prototype.K;gx.prototype.getTileCoord=gx.prototype.i;gx.prototype.load=gx.prototype.load;G.prototype.get=G.prototype.get;G.prototype.getKeys=G.prototype.P;G.prototype.getProperties=G.prototype.M;G.prototype.set=G.prototype.set;G.prototype.setProperties=G.prototype.H;G.prototype.unset=G.prototype.R;G.prototype.changed=G.prototype.s;G.prototype.dispatchEvent=G.prototype.b;
G.prototype.getRevision=G.prototype.L;G.prototype.on=G.prototype.J;G.prototype.once=G.prototype.once;G.prototype.un=G.prototype.K;jx.prototype.forEachTileCoord=jx.prototype.mh;jx.prototype.getMaxZoom=jx.prototype.Ni;jx.prototype.getMinZoom=jx.prototype.Oi;jx.prototype.getOrigin=jx.prototype.Uc;jx.prototype.getResolution=jx.prototype.La;jx.prototype.getResolutions=jx.prototype.Pi;jx.prototype.getTileCoordExtent=jx.prototype.Ua;jx.prototype.getTileCoordForCoordAndResolution=jx.prototype.Ae;
jx.prototype.getTileCoordForCoordAndZ=jx.prototype.Xf;jx.prototype.getTileSize=jx.prototype.eb;jx.prototype.getZForResolution=jx.prototype.Qc;Yk.prototype.getOpacity=Yk.prototype.Ye;Yk.prototype.getRotateWithView=Yk.prototype.Ze;Yk.prototype.getRotation=Yk.prototype.$e;Yk.prototype.getScale=Yk.prototype.af;Yk.prototype.getSnapToPixel=Yk.prototype.ze;Yk.prototype.setOpacity=Yk.prototype.vd;Yk.prototype.setRotation=Yk.prototype.bf;Yk.prototype.setScale=Yk.prototype.wd;$k.prototype.clone=$k.prototype.clone;
$k.prototype.getAngle=$k.prototype.Ji;$k.prototype.getFill=$k.prototype.Ca;$k.prototype.getPoints=$k.prototype.Ki;$k.prototype.getRadius=$k.prototype.Li;$k.prototype.getRadius2=$k.prototype.yh;$k.prototype.getStroke=$k.prototype.Da;$k.prototype.getOpacity=$k.prototype.Ye;$k.prototype.getRotateWithView=$k.prototype.Ze;$k.prototype.getRotation=$k.prototype.$e;$k.prototype.getScale=$k.prototype.af;$k.prototype.getSnapToPixel=$k.prototype.ze;$k.prototype.setOpacity=$k.prototype.vd;
$k.prototype.setRotation=$k.prototype.bf;$k.prototype.setScale=$k.prototype.wd;co.prototype.getOpacity=co.prototype.Ye;co.prototype.getRotateWithView=co.prototype.Ze;co.prototype.getRotation=co.prototype.$e;co.prototype.getScale=co.prototype.af;co.prototype.getSnapToPixel=co.prototype.ze;co.prototype.setOpacity=co.prototype.vd;co.prototype.setRotation=co.prototype.bf;co.prototype.setScale=co.prototype.wd;Tt.prototype.get=Tt.prototype.get;Tt.prototype.getKeys=Tt.prototype.P;
Tt.prototype.getProperties=Tt.prototype.M;Tt.prototype.set=Tt.prototype.set;Tt.prototype.setProperties=Tt.prototype.H;Tt.prototype.unset=Tt.prototype.R;Tt.prototype.changed=Tt.prototype.s;Tt.prototype.dispatchEvent=Tt.prototype.b;Tt.prototype.getRevision=Tt.prototype.L;Tt.prototype.on=Tt.prototype.J;Tt.prototype.once=Tt.prototype.once;Tt.prototype.un=Tt.prototype.K;iw.prototype.getAttributions=iw.prototype.xa;iw.prototype.getLogo=iw.prototype.wa;iw.prototype.getProjection=iw.prototype.ya;
iw.prototype.getState=iw.prototype.V;iw.prototype.refresh=iw.prototype.va;iw.prototype.setAttributions=iw.prototype.ua;iw.prototype.get=iw.prototype.get;iw.prototype.getKeys=iw.prototype.P;iw.prototype.getProperties=iw.prototype.M;iw.prototype.set=iw.prototype.set;iw.prototype.setProperties=iw.prototype.H;iw.prototype.unset=iw.prototype.R;iw.prototype.changed=iw.prototype.s;iw.prototype.dispatchEvent=iw.prototype.b;iw.prototype.getRevision=iw.prototype.L;iw.prototype.on=iw.prototype.J;
iw.prototype.once=iw.prototype.once;iw.prototype.un=iw.prototype.K;mw.prototype.getTileGrid=mw.prototype.ab;mw.prototype.refresh=mw.prototype.va;mw.prototype.getAttributions=mw.prototype.xa;mw.prototype.getLogo=mw.prototype.wa;mw.prototype.getProjection=mw.prototype.ya;mw.prototype.getState=mw.prototype.V;mw.prototype.setAttributions=mw.prototype.ua;mw.prototype.get=mw.prototype.get;mw.prototype.getKeys=mw.prototype.P;mw.prototype.getProperties=mw.prototype.M;mw.prototype.set=mw.prototype.set;
mw.prototype.setProperties=mw.prototype.H;mw.prototype.unset=mw.prototype.R;mw.prototype.changed=mw.prototype.s;mw.prototype.dispatchEvent=mw.prototype.b;mw.prototype.getRevision=mw.prototype.L;mw.prototype.on=mw.prototype.J;mw.prototype.once=mw.prototype.once;mw.prototype.un=mw.prototype.K;W.prototype.getTileLoadFunction=W.prototype.ob;W.prototype.getTileUrlFunction=W.prototype.qb;W.prototype.getUrls=W.prototype.rb;W.prototype.setTileLoadFunction=W.prototype.wb;W.prototype.setTileUrlFunction=W.prototype.bb;
W.prototype.setUrl=W.prototype.ib;W.prototype.setUrls=W.prototype.cb;W.prototype.getTileGrid=W.prototype.ab;W.prototype.refresh=W.prototype.va;W.prototype.getAttributions=W.prototype.xa;W.prototype.getLogo=W.prototype.wa;W.prototype.getProjection=W.prototype.ya;W.prototype.getState=W.prototype.V;W.prototype.setAttributions=W.prototype.ua;W.prototype.get=W.prototype.get;W.prototype.getKeys=W.prototype.P;W.prototype.getProperties=W.prototype.M;W.prototype.set=W.prototype.set;
W.prototype.setProperties=W.prototype.H;W.prototype.unset=W.prototype.R;W.prototype.changed=W.prototype.s;W.prototype.dispatchEvent=W.prototype.b;W.prototype.getRevision=W.prototype.L;W.prototype.on=W.prototype.J;W.prototype.once=W.prototype.once;W.prototype.un=W.prototype.K;qw.prototype.setRenderReprojectionEdges=qw.prototype.Ob;qw.prototype.setTileGridForProjection=qw.prototype.Pb;qw.prototype.getTileLoadFunction=qw.prototype.ob;qw.prototype.getTileUrlFunction=qw.prototype.qb;
qw.prototype.getUrls=qw.prototype.rb;qw.prototype.setTileLoadFunction=qw.prototype.wb;qw.prototype.setTileUrlFunction=qw.prototype.bb;qw.prototype.setUrl=qw.prototype.ib;qw.prototype.setUrls=qw.prototype.cb;qw.prototype.getTileGrid=qw.prototype.ab;qw.prototype.refresh=qw.prototype.va;qw.prototype.getAttributions=qw.prototype.xa;qw.prototype.getLogo=qw.prototype.wa;qw.prototype.getProjection=qw.prototype.ya;qw.prototype.getState=qw.prototype.V;qw.prototype.setAttributions=qw.prototype.ua;
qw.prototype.get=qw.prototype.get;qw.prototype.getKeys=qw.prototype.P;qw.prototype.getProperties=qw.prototype.M;qw.prototype.set=qw.prototype.set;qw.prototype.setProperties=qw.prototype.H;qw.prototype.unset=qw.prototype.R;qw.prototype.changed=qw.prototype.s;qw.prototype.dispatchEvent=qw.prototype.b;qw.prototype.getRevision=qw.prototype.L;qw.prototype.on=qw.prototype.J;qw.prototype.once=qw.prototype.once;qw.prototype.un=qw.prototype.K;sw.prototype.setRenderReprojectionEdges=sw.prototype.Ob;
sw.prototype.setTileGridForProjection=sw.prototype.Pb;sw.prototype.getTileLoadFunction=sw.prototype.ob;sw.prototype.getTileUrlFunction=sw.prototype.qb;sw.prototype.getUrls=sw.prototype.rb;sw.prototype.setTileLoadFunction=sw.prototype.wb;sw.prototype.setTileUrlFunction=sw.prototype.bb;sw.prototype.setUrl=sw.prototype.ib;sw.prototype.setUrls=sw.prototype.cb;sw.prototype.getTileGrid=sw.prototype.ab;sw.prototype.refresh=sw.prototype.va;sw.prototype.getAttributions=sw.prototype.xa;
sw.prototype.getLogo=sw.prototype.wa;sw.prototype.getProjection=sw.prototype.ya;sw.prototype.getState=sw.prototype.V;sw.prototype.setAttributions=sw.prototype.ua;sw.prototype.get=sw.prototype.get;sw.prototype.getKeys=sw.prototype.P;sw.prototype.getProperties=sw.prototype.M;sw.prototype.set=sw.prototype.set;sw.prototype.setProperties=sw.prototype.H;sw.prototype.unset=sw.prototype.R;sw.prototype.changed=sw.prototype.s;sw.prototype.dispatchEvent=sw.prototype.b;sw.prototype.getRevision=sw.prototype.L;
sw.prototype.on=sw.prototype.J;sw.prototype.once=sw.prototype.once;sw.prototype.un=sw.prototype.K;tw.prototype.setRenderReprojectionEdges=tw.prototype.Ob;tw.prototype.setTileGridForProjection=tw.prototype.Pb;tw.prototype.getTileLoadFunction=tw.prototype.ob;tw.prototype.getTileUrlFunction=tw.prototype.qb;tw.prototype.getUrls=tw.prototype.rb;tw.prototype.setTileLoadFunction=tw.prototype.wb;tw.prototype.setTileUrlFunction=tw.prototype.bb;tw.prototype.setUrl=tw.prototype.ib;tw.prototype.setUrls=tw.prototype.cb;
tw.prototype.getTileGrid=tw.prototype.ab;tw.prototype.refresh=tw.prototype.va;tw.prototype.getAttributions=tw.prototype.xa;tw.prototype.getLogo=tw.prototype.wa;tw.prototype.getProjection=tw.prototype.ya;tw.prototype.getState=tw.prototype.V;tw.prototype.setAttributions=tw.prototype.ua;tw.prototype.get=tw.prototype.get;tw.prototype.getKeys=tw.prototype.P;tw.prototype.getProperties=tw.prototype.M;tw.prototype.set=tw.prototype.set;tw.prototype.setProperties=tw.prototype.H;tw.prototype.unset=tw.prototype.R;
tw.prototype.changed=tw.prototype.s;tw.prototype.dispatchEvent=tw.prototype.b;tw.prototype.getRevision=tw.prototype.L;tw.prototype.on=tw.prototype.J;tw.prototype.once=tw.prototype.once;tw.prototype.un=tw.prototype.K;T.prototype.getAttributions=T.prototype.xa;T.prototype.getLogo=T.prototype.wa;T.prototype.getProjection=T.prototype.ya;T.prototype.getState=T.prototype.V;T.prototype.refresh=T.prototype.va;T.prototype.setAttributions=T.prototype.ua;T.prototype.get=T.prototype.get;T.prototype.getKeys=T.prototype.P;
T.prototype.getProperties=T.prototype.M;T.prototype.set=T.prototype.set;T.prototype.setProperties=T.prototype.H;T.prototype.unset=T.prototype.R;T.prototype.changed=T.prototype.s;T.prototype.dispatchEvent=T.prototype.b;T.prototype.getRevision=T.prototype.L;T.prototype.on=T.prototype.J;T.prototype.once=T.prototype.once;T.prototype.un=T.prototype.K;X.prototype.addFeature=X.prototype.zb;X.prototype.addFeatures=X.prototype.gd;X.prototype.clear=X.prototype.clear;X.prototype.forEachFeature=X.prototype.kh;
X.prototype.forEachFeatureInExtent=X.prototype.bc;X.prototype.forEachFeatureIntersectingExtent=X.prototype.lh;X.prototype.getFeaturesCollection=X.prototype.th;X.prototype.getFeatures=X.prototype.We;X.prototype.getFeaturesAtCoordinate=X.prototype.sh;X.prototype.getFeaturesInExtent=X.prototype.Pf;X.prototype.getClosestFeatureToCoordinate=X.prototype.oh;X.prototype.getExtent=X.prototype.D;X.prototype.getFeatureById=X.prototype.rh;X.prototype.getFormat=X.prototype.Gi;X.prototype.getUrl=X.prototype.Hi;
X.prototype.removeFeature=X.prototype.Db;X.prototype.getAttributions=X.prototype.xa;X.prototype.getLogo=X.prototype.wa;X.prototype.getProjection=X.prototype.ya;X.prototype.getState=X.prototype.V;X.prototype.refresh=X.prototype.va;X.prototype.setAttributions=X.prototype.ua;X.prototype.get=X.prototype.get;X.prototype.getKeys=X.prototype.P;X.prototype.getProperties=X.prototype.M;X.prototype.set=X.prototype.set;X.prototype.setProperties=X.prototype.H;X.prototype.unset=X.prototype.R;
X.prototype.changed=X.prototype.s;X.prototype.dispatchEvent=X.prototype.b;X.prototype.getRevision=X.prototype.L;X.prototype.on=X.prototype.J;X.prototype.once=X.prototype.once;X.prototype.un=X.prototype.K;zv.prototype.getAttributions=zv.prototype.xa;zv.prototype.getLogo=zv.prototype.wa;zv.prototype.getProjection=zv.prototype.ya;zv.prototype.getState=zv.prototype.V;zv.prototype.refresh=zv.prototype.va;zv.prototype.setAttributions=zv.prototype.ua;zv.prototype.get=zv.prototype.get;
zv.prototype.getKeys=zv.prototype.P;zv.prototype.getProperties=zv.prototype.M;zv.prototype.set=zv.prototype.set;zv.prototype.setProperties=zv.prototype.H;zv.prototype.unset=zv.prototype.R;zv.prototype.changed=zv.prototype.s;zv.prototype.dispatchEvent=zv.prototype.b;zv.prototype.getRevision=zv.prototype.L;zv.prototype.on=zv.prototype.J;zv.prototype.once=zv.prototype.once;zv.prototype.un=zv.prototype.K;Bv.prototype.type=Bv.prototype.type;Bv.prototype.target=Bv.prototype.target;
Bv.prototype.preventDefault=Bv.prototype.preventDefault;Bv.prototype.stopPropagation=Bv.prototype.stopPropagation;zw.prototype.getAttributions=zw.prototype.xa;zw.prototype.getLogo=zw.prototype.wa;zw.prototype.getProjection=zw.prototype.ya;zw.prototype.getState=zw.prototype.V;zw.prototype.refresh=zw.prototype.va;zw.prototype.setAttributions=zw.prototype.ua;zw.prototype.get=zw.prototype.get;zw.prototype.getKeys=zw.prototype.P;zw.prototype.getProperties=zw.prototype.M;zw.prototype.set=zw.prototype.set;
zw.prototype.setProperties=zw.prototype.H;zw.prototype.unset=zw.prototype.R;zw.prototype.changed=zw.prototype.s;zw.prototype.dispatchEvent=zw.prototype.b;zw.prototype.getRevision=zw.prototype.L;zw.prototype.on=zw.prototype.J;zw.prototype.once=zw.prototype.once;zw.prototype.un=zw.prototype.K;Gv.prototype.getAttributions=Gv.prototype.xa;Gv.prototype.getLogo=Gv.prototype.wa;Gv.prototype.getProjection=Gv.prototype.ya;Gv.prototype.getState=Gv.prototype.V;Gv.prototype.refresh=Gv.prototype.va;
Gv.prototype.setAttributions=Gv.prototype.ua;Gv.prototype.get=Gv.prototype.get;Gv.prototype.getKeys=Gv.prototype.P;Gv.prototype.getProperties=Gv.prototype.M;Gv.prototype.set=Gv.prototype.set;Gv.prototype.setProperties=Gv.prototype.H;Gv.prototype.unset=Gv.prototype.R;Gv.prototype.changed=Gv.prototype.s;Gv.prototype.dispatchEvent=Gv.prototype.b;Gv.prototype.getRevision=Gv.prototype.L;Gv.prototype.on=Gv.prototype.J;Gv.prototype.once=Gv.prototype.once;Gv.prototype.un=Gv.prototype.K;
Aw.prototype.getAttributions=Aw.prototype.xa;Aw.prototype.getLogo=Aw.prototype.wa;Aw.prototype.getProjection=Aw.prototype.ya;Aw.prototype.getState=Aw.prototype.V;Aw.prototype.refresh=Aw.prototype.va;Aw.prototype.setAttributions=Aw.prototype.ua;Aw.prototype.get=Aw.prototype.get;Aw.prototype.getKeys=Aw.prototype.P;Aw.prototype.getProperties=Aw.prototype.M;Aw.prototype.set=Aw.prototype.set;Aw.prototype.setProperties=Aw.prototype.H;Aw.prototype.unset=Aw.prototype.R;Aw.prototype.changed=Aw.prototype.s;
Aw.prototype.dispatchEvent=Aw.prototype.b;Aw.prototype.getRevision=Aw.prototype.L;Aw.prototype.on=Aw.prototype.J;Aw.prototype.once=Aw.prototype.once;Aw.prototype.un=Aw.prototype.K;Bw.prototype.getAttributions=Bw.prototype.xa;Bw.prototype.getLogo=Bw.prototype.wa;Bw.prototype.getProjection=Bw.prototype.ya;Bw.prototype.getState=Bw.prototype.V;Bw.prototype.refresh=Bw.prototype.va;Bw.prototype.setAttributions=Bw.prototype.ua;Bw.prototype.get=Bw.prototype.get;Bw.prototype.getKeys=Bw.prototype.P;
Bw.prototype.getProperties=Bw.prototype.M;Bw.prototype.set=Bw.prototype.set;Bw.prototype.setProperties=Bw.prototype.H;Bw.prototype.unset=Bw.prototype.R;Bw.prototype.changed=Bw.prototype.s;Bw.prototype.dispatchEvent=Bw.prototype.b;Bw.prototype.getRevision=Bw.prototype.L;Bw.prototype.on=Bw.prototype.J;Bw.prototype.once=Bw.prototype.once;Bw.prototype.un=Bw.prototype.K;Hv.prototype.getAttributions=Hv.prototype.xa;Hv.prototype.getLogo=Hv.prototype.wa;Hv.prototype.getProjection=Hv.prototype.ya;
Hv.prototype.getState=Hv.prototype.V;Hv.prototype.refresh=Hv.prototype.va;Hv.prototype.setAttributions=Hv.prototype.ua;Hv.prototype.get=Hv.prototype.get;Hv.prototype.getKeys=Hv.prototype.P;Hv.prototype.getProperties=Hv.prototype.M;Hv.prototype.set=Hv.prototype.set;Hv.prototype.setProperties=Hv.prototype.H;Hv.prototype.unset=Hv.prototype.R;Hv.prototype.changed=Hv.prototype.s;Hv.prototype.dispatchEvent=Hv.prototype.b;Hv.prototype.getRevision=Hv.prototype.L;Hv.prototype.on=Hv.prototype.J;
Hv.prototype.once=Hv.prototype.once;Hv.prototype.un=Hv.prototype.K;Cw.prototype.getAttributions=Cw.prototype.xa;Cw.prototype.getLogo=Cw.prototype.wa;Cw.prototype.getProjection=Cw.prototype.ya;Cw.prototype.getState=Cw.prototype.V;Cw.prototype.refresh=Cw.prototype.va;Cw.prototype.setAttributions=Cw.prototype.ua;Cw.prototype.get=Cw.prototype.get;Cw.prototype.getKeys=Cw.prototype.P;Cw.prototype.getProperties=Cw.prototype.M;Cw.prototype.set=Cw.prototype.set;Cw.prototype.setProperties=Cw.prototype.H;
Cw.prototype.unset=Cw.prototype.R;Cw.prototype.changed=Cw.prototype.s;Cw.prototype.dispatchEvent=Cw.prototype.b;Cw.prototype.getRevision=Cw.prototype.L;Cw.prototype.on=Cw.prototype.J;Cw.prototype.once=Cw.prototype.once;Cw.prototype.un=Cw.prototype.K;Gw.prototype.setRenderReprojectionEdges=Gw.prototype.Ob;Gw.prototype.setTileGridForProjection=Gw.prototype.Pb;Gw.prototype.getTileLoadFunction=Gw.prototype.ob;Gw.prototype.getTileUrlFunction=Gw.prototype.qb;Gw.prototype.getUrls=Gw.prototype.rb;
Gw.prototype.setTileLoadFunction=Gw.prototype.wb;Gw.prototype.setTileUrlFunction=Gw.prototype.bb;Gw.prototype.setUrl=Gw.prototype.ib;Gw.prototype.setUrls=Gw.prototype.cb;Gw.prototype.getTileGrid=Gw.prototype.ab;Gw.prototype.refresh=Gw.prototype.va;Gw.prototype.getAttributions=Gw.prototype.xa;Gw.prototype.getLogo=Gw.prototype.wa;Gw.prototype.getProjection=Gw.prototype.ya;Gw.prototype.getState=Gw.prototype.V;Gw.prototype.setAttributions=Gw.prototype.ua;Gw.prototype.get=Gw.prototype.get;
Gw.prototype.getKeys=Gw.prototype.P;Gw.prototype.getProperties=Gw.prototype.M;Gw.prototype.set=Gw.prototype.set;Gw.prototype.setProperties=Gw.prototype.H;Gw.prototype.unset=Gw.prototype.R;Gw.prototype.changed=Gw.prototype.s;Gw.prototype.dispatchEvent=Gw.prototype.b;Gw.prototype.getRevision=Gw.prototype.L;Gw.prototype.on=Gw.prototype.J;Gw.prototype.once=Gw.prototype.once;Gw.prototype.un=Gw.prototype.K;Iw.prototype.getAttributions=Iw.prototype.xa;Iw.prototype.getLogo=Iw.prototype.wa;
Iw.prototype.getProjection=Iw.prototype.ya;Iw.prototype.getState=Iw.prototype.V;Iw.prototype.refresh=Iw.prototype.va;Iw.prototype.setAttributions=Iw.prototype.ua;Iw.prototype.get=Iw.prototype.get;Iw.prototype.getKeys=Iw.prototype.P;Iw.prototype.getProperties=Iw.prototype.M;Iw.prototype.set=Iw.prototype.set;Iw.prototype.setProperties=Iw.prototype.H;Iw.prototype.unset=Iw.prototype.R;Iw.prototype.changed=Iw.prototype.s;Iw.prototype.dispatchEvent=Iw.prototype.b;Iw.prototype.getRevision=Iw.prototype.L;
Iw.prototype.on=Iw.prototype.J;Iw.prototype.once=Iw.prototype.once;Iw.prototype.un=Iw.prototype.K;Mw.prototype.type=Mw.prototype.type;Mw.prototype.target=Mw.prototype.target;Mw.prototype.preventDefault=Mw.prototype.preventDefault;Mw.prototype.stopPropagation=Mw.prototype.stopPropagation;Pw.prototype.setRenderReprojectionEdges=Pw.prototype.Ob;Pw.prototype.setTileGridForProjection=Pw.prototype.Pb;Pw.prototype.getTileLoadFunction=Pw.prototype.ob;Pw.prototype.getTileUrlFunction=Pw.prototype.qb;
Pw.prototype.getUrls=Pw.prototype.rb;Pw.prototype.setTileLoadFunction=Pw.prototype.wb;Pw.prototype.setTileUrlFunction=Pw.prototype.bb;Pw.prototype.setUrl=Pw.prototype.ib;Pw.prototype.setUrls=Pw.prototype.cb;Pw.prototype.getTileGrid=Pw.prototype.ab;Pw.prototype.refresh=Pw.prototype.va;Pw.prototype.getAttributions=Pw.prototype.xa;Pw.prototype.getLogo=Pw.prototype.wa;Pw.prototype.getProjection=Pw.prototype.ya;Pw.prototype.getState=Pw.prototype.V;Pw.prototype.setAttributions=Pw.prototype.ua;
Pw.prototype.get=Pw.prototype.get;Pw.prototype.getKeys=Pw.prototype.P;Pw.prototype.getProperties=Pw.prototype.M;Pw.prototype.set=Pw.prototype.set;Pw.prototype.setProperties=Pw.prototype.H;Pw.prototype.unset=Pw.prototype.R;Pw.prototype.changed=Pw.prototype.s;Pw.prototype.dispatchEvent=Pw.prototype.b;Pw.prototype.getRevision=Pw.prototype.L;Pw.prototype.on=Pw.prototype.J;Pw.prototype.once=Pw.prototype.once;Pw.prototype.un=Pw.prototype.K;lw.prototype.type=lw.prototype.type;lw.prototype.target=lw.prototype.target;
lw.prototype.preventDefault=lw.prototype.preventDefault;lw.prototype.stopPropagation=lw.prototype.stopPropagation;Tw.prototype.setRenderReprojectionEdges=Tw.prototype.Ob;Tw.prototype.setTileGridForProjection=Tw.prototype.Pb;Tw.prototype.getTileLoadFunction=Tw.prototype.ob;Tw.prototype.getTileUrlFunction=Tw.prototype.qb;Tw.prototype.getUrls=Tw.prototype.rb;Tw.prototype.setTileLoadFunction=Tw.prototype.wb;Tw.prototype.setTileUrlFunction=Tw.prototype.bb;Tw.prototype.setUrl=Tw.prototype.ib;
Tw.prototype.setUrls=Tw.prototype.cb;Tw.prototype.getTileGrid=Tw.prototype.ab;Tw.prototype.refresh=Tw.prototype.va;Tw.prototype.getAttributions=Tw.prototype.xa;Tw.prototype.getLogo=Tw.prototype.wa;Tw.prototype.getProjection=Tw.prototype.ya;Tw.prototype.getState=Tw.prototype.V;Tw.prototype.setAttributions=Tw.prototype.ua;Tw.prototype.get=Tw.prototype.get;Tw.prototype.getKeys=Tw.prototype.P;Tw.prototype.getProperties=Tw.prototype.M;Tw.prototype.set=Tw.prototype.set;Tw.prototype.setProperties=Tw.prototype.H;
Tw.prototype.unset=Tw.prototype.R;Tw.prototype.changed=Tw.prototype.s;Tw.prototype.dispatchEvent=Tw.prototype.b;Tw.prototype.getRevision=Tw.prototype.L;Tw.prototype.on=Tw.prototype.J;Tw.prototype.once=Tw.prototype.once;Tw.prototype.un=Tw.prototype.K;Vw.prototype.getTileGrid=Vw.prototype.ab;Vw.prototype.refresh=Vw.prototype.va;Vw.prototype.getAttributions=Vw.prototype.xa;Vw.prototype.getLogo=Vw.prototype.wa;Vw.prototype.getProjection=Vw.prototype.ya;Vw.prototype.getState=Vw.prototype.V;
Vw.prototype.setAttributions=Vw.prototype.ua;Vw.prototype.get=Vw.prototype.get;Vw.prototype.getKeys=Vw.prototype.P;Vw.prototype.getProperties=Vw.prototype.M;Vw.prototype.set=Vw.prototype.set;Vw.prototype.setProperties=Vw.prototype.H;Vw.prototype.unset=Vw.prototype.R;Vw.prototype.changed=Vw.prototype.s;Vw.prototype.dispatchEvent=Vw.prototype.b;Vw.prototype.getRevision=Vw.prototype.L;Vw.prototype.on=Vw.prototype.J;Vw.prototype.once=Vw.prototype.once;Vw.prototype.un=Vw.prototype.K;
Xw.prototype.setRenderReprojectionEdges=Xw.prototype.Ob;Xw.prototype.setTileGridForProjection=Xw.prototype.Pb;Xw.prototype.getTileLoadFunction=Xw.prototype.ob;Xw.prototype.getTileUrlFunction=Xw.prototype.qb;Xw.prototype.getUrls=Xw.prototype.rb;Xw.prototype.setTileLoadFunction=Xw.prototype.wb;Xw.prototype.setTileUrlFunction=Xw.prototype.bb;Xw.prototype.setUrl=Xw.prototype.ib;Xw.prototype.setUrls=Xw.prototype.cb;Xw.prototype.getTileGrid=Xw.prototype.ab;Xw.prototype.refresh=Xw.prototype.va;
Xw.prototype.getAttributions=Xw.prototype.xa;Xw.prototype.getLogo=Xw.prototype.wa;Xw.prototype.getProjection=Xw.prototype.ya;Xw.prototype.getState=Xw.prototype.V;Xw.prototype.setAttributions=Xw.prototype.ua;Xw.prototype.get=Xw.prototype.get;Xw.prototype.getKeys=Xw.prototype.P;Xw.prototype.getProperties=Xw.prototype.M;Xw.prototype.set=Xw.prototype.set;Xw.prototype.setProperties=Xw.prototype.H;Xw.prototype.unset=Xw.prototype.R;Xw.prototype.changed=Xw.prototype.s;Xw.prototype.dispatchEvent=Xw.prototype.b;
Xw.prototype.getRevision=Xw.prototype.L;Xw.prototype.on=Xw.prototype.J;Xw.prototype.once=Xw.prototype.once;Xw.prototype.un=Xw.prototype.K;Yw.prototype.getTileGrid=Yw.prototype.ab;Yw.prototype.refresh=Yw.prototype.va;Yw.prototype.getAttributions=Yw.prototype.xa;Yw.prototype.getLogo=Yw.prototype.wa;Yw.prototype.getProjection=Yw.prototype.ya;Yw.prototype.getState=Yw.prototype.V;Yw.prototype.setAttributions=Yw.prototype.ua;Yw.prototype.get=Yw.prototype.get;Yw.prototype.getKeys=Yw.prototype.P;
Yw.prototype.getProperties=Yw.prototype.M;Yw.prototype.set=Yw.prototype.set;Yw.prototype.setProperties=Yw.prototype.H;Yw.prototype.unset=Yw.prototype.R;Yw.prototype.changed=Yw.prototype.s;Yw.prototype.dispatchEvent=Yw.prototype.b;Yw.prototype.getRevision=Yw.prototype.L;Yw.prototype.on=Yw.prototype.J;Yw.prototype.once=Yw.prototype.once;Yw.prototype.un=Yw.prototype.K;bx.prototype.setRenderReprojectionEdges=bx.prototype.Ob;bx.prototype.setTileGridForProjection=bx.prototype.Pb;
bx.prototype.getTileLoadFunction=bx.prototype.ob;bx.prototype.getTileUrlFunction=bx.prototype.qb;bx.prototype.getUrls=bx.prototype.rb;bx.prototype.setTileLoadFunction=bx.prototype.wb;bx.prototype.setTileUrlFunction=bx.prototype.bb;bx.prototype.setUrl=bx.prototype.ib;bx.prototype.setUrls=bx.prototype.cb;bx.prototype.getTileGrid=bx.prototype.ab;bx.prototype.refresh=bx.prototype.va;bx.prototype.getAttributions=bx.prototype.xa;bx.prototype.getLogo=bx.prototype.wa;bx.prototype.getProjection=bx.prototype.ya;
bx.prototype.getState=bx.prototype.V;bx.prototype.setAttributions=bx.prototype.ua;bx.prototype.get=bx.prototype.get;bx.prototype.getKeys=bx.prototype.P;bx.prototype.getProperties=bx.prototype.M;bx.prototype.set=bx.prototype.set;bx.prototype.setProperties=bx.prototype.H;bx.prototype.unset=bx.prototype.R;bx.prototype.changed=bx.prototype.s;bx.prototype.dispatchEvent=bx.prototype.b;bx.prototype.getRevision=bx.prototype.L;bx.prototype.on=bx.prototype.J;bx.prototype.once=bx.prototype.once;
bx.prototype.un=bx.prototype.K;$t.prototype.type=$t.prototype.type;$t.prototype.target=$t.prototype.target;$t.prototype.preventDefault=$t.prototype.preventDefault;$t.prototype.stopPropagation=$t.prototype.stopPropagation;ix.prototype.getTileLoadFunction=ix.prototype.ob;ix.prototype.getTileUrlFunction=ix.prototype.qb;ix.prototype.getUrls=ix.prototype.rb;ix.prototype.setTileLoadFunction=ix.prototype.wb;ix.prototype.setTileUrlFunction=ix.prototype.bb;ix.prototype.setUrl=ix.prototype.ib;
ix.prototype.setUrls=ix.prototype.cb;ix.prototype.getTileGrid=ix.prototype.ab;ix.prototype.refresh=ix.prototype.va;ix.prototype.getAttributions=ix.prototype.xa;ix.prototype.getLogo=ix.prototype.wa;ix.prototype.getProjection=ix.prototype.ya;ix.prototype.getState=ix.prototype.V;ix.prototype.setAttributions=ix.prototype.ua;ix.prototype.get=ix.prototype.get;ix.prototype.getKeys=ix.prototype.P;ix.prototype.getProperties=ix.prototype.M;ix.prototype.set=ix.prototype.set;ix.prototype.setProperties=ix.prototype.H;
ix.prototype.unset=ix.prototype.R;ix.prototype.changed=ix.prototype.s;ix.prototype.dispatchEvent=ix.prototype.b;ix.prototype.getRevision=ix.prototype.L;ix.prototype.on=ix.prototype.J;ix.prototype.once=ix.prototype.once;ix.prototype.un=ix.prototype.K;Y.prototype.setRenderReprojectionEdges=Y.prototype.Ob;Y.prototype.setTileGridForProjection=Y.prototype.Pb;Y.prototype.getTileLoadFunction=Y.prototype.ob;Y.prototype.getTileUrlFunction=Y.prototype.qb;Y.prototype.getUrls=Y.prototype.rb;
Y.prototype.setTileLoadFunction=Y.prototype.wb;Y.prototype.setTileUrlFunction=Y.prototype.bb;Y.prototype.setUrl=Y.prototype.ib;Y.prototype.setUrls=Y.prototype.cb;Y.prototype.getTileGrid=Y.prototype.ab;Y.prototype.refresh=Y.prototype.va;Y.prototype.getAttributions=Y.prototype.xa;Y.prototype.getLogo=Y.prototype.wa;Y.prototype.getProjection=Y.prototype.ya;Y.prototype.getState=Y.prototype.V;Y.prototype.setAttributions=Y.prototype.ua;Y.prototype.get=Y.prototype.get;Y.prototype.getKeys=Y.prototype.P;
Y.prototype.getProperties=Y.prototype.M;Y.prototype.set=Y.prototype.set;Y.prototype.setProperties=Y.prototype.H;Y.prototype.unset=Y.prototype.R;Y.prototype.changed=Y.prototype.s;Y.prototype.dispatchEvent=Y.prototype.b;Y.prototype.getRevision=Y.prototype.L;Y.prototype.on=Y.prototype.J;Y.prototype.once=Y.prototype.once;Y.prototype.un=Y.prototype.K;mx.prototype.setRenderReprojectionEdges=mx.prototype.Ob;mx.prototype.setTileGridForProjection=mx.prototype.Pb;mx.prototype.getTileLoadFunction=mx.prototype.ob;
mx.prototype.getTileUrlFunction=mx.prototype.qb;mx.prototype.getUrls=mx.prototype.rb;mx.prototype.setTileLoadFunction=mx.prototype.wb;mx.prototype.setTileUrlFunction=mx.prototype.bb;mx.prototype.setUrl=mx.prototype.ib;mx.prototype.setUrls=mx.prototype.cb;mx.prototype.getTileGrid=mx.prototype.ab;mx.prototype.refresh=mx.prototype.va;mx.prototype.getAttributions=mx.prototype.xa;mx.prototype.getLogo=mx.prototype.wa;mx.prototype.getProjection=mx.prototype.ya;mx.prototype.getState=mx.prototype.V;
mx.prototype.setAttributions=mx.prototype.ua;mx.prototype.get=mx.prototype.get;mx.prototype.getKeys=mx.prototype.P;mx.prototype.getProperties=mx.prototype.M;mx.prototype.set=mx.prototype.set;mx.prototype.setProperties=mx.prototype.H;mx.prototype.unset=mx.prototype.R;mx.prototype.changed=mx.prototype.s;mx.prototype.dispatchEvent=mx.prototype.b;mx.prototype.getRevision=mx.prototype.L;mx.prototype.on=mx.prototype.J;mx.prototype.once=mx.prototype.once;mx.prototype.un=mx.prototype.K;
aw.prototype.getTileCoord=aw.prototype.i;aw.prototype.load=aw.prototype.load;qt.prototype.changed=qt.prototype.s;qt.prototype.dispatchEvent=qt.prototype.b;qt.prototype.getRevision=qt.prototype.L;qt.prototype.on=qt.prototype.J;qt.prototype.once=qt.prototype.once;qt.prototype.un=qt.prototype.K;Ot.prototype.changed=Ot.prototype.s;Ot.prototype.dispatchEvent=Ot.prototype.b;Ot.prototype.getRevision=Ot.prototype.L;Ot.prototype.on=Ot.prototype.J;Ot.prototype.once=Ot.prototype.once;Ot.prototype.un=Ot.prototype.K;
Jv.prototype.changed=Jv.prototype.s;Jv.prototype.dispatchEvent=Jv.prototype.b;Jv.prototype.getRevision=Jv.prototype.L;Jv.prototype.on=Jv.prototype.J;Jv.prototype.once=Jv.prototype.once;Jv.prototype.un=Jv.prototype.K;Uv.prototype.changed=Uv.prototype.s;Uv.prototype.dispatchEvent=Uv.prototype.b;Uv.prototype.getRevision=Uv.prototype.L;Uv.prototype.on=Uv.prototype.J;Uv.prototype.once=Uv.prototype.once;Uv.prototype.un=Uv.prototype.K;Rt.prototype.changed=Rt.prototype.s;Rt.prototype.dispatchEvent=Rt.prototype.b;
Rt.prototype.getRevision=Rt.prototype.L;Rt.prototype.on=Rt.prototype.J;Rt.prototype.once=Rt.prototype.once;Rt.prototype.un=Rt.prototype.K;zt.prototype.changed=zt.prototype.s;zt.prototype.dispatchEvent=zt.prototype.b;zt.prototype.getRevision=zt.prototype.L;zt.prototype.on=zt.prototype.J;zt.prototype.once=zt.prototype.once;zt.prototype.un=zt.prototype.K;qv.prototype.changed=qv.prototype.s;qv.prototype.dispatchEvent=qv.prototype.b;qv.prototype.getRevision=qv.prototype.L;qv.prototype.on=qv.prototype.J;
qv.prototype.once=qv.prototype.once;qv.prototype.un=qv.prototype.K;rv.prototype.changed=rv.prototype.s;rv.prototype.dispatchEvent=rv.prototype.b;rv.prototype.getRevision=rv.prototype.L;rv.prototype.on=rv.prototype.J;rv.prototype.once=rv.prototype.once;rv.prototype.un=rv.prototype.K;Nv.prototype.changed=Nv.prototype.s;Nv.prototype.dispatchEvent=Nv.prototype.b;Nv.prototype.getRevision=Nv.prototype.L;Nv.prototype.on=Nv.prototype.J;Nv.prototype.once=Nv.prototype.once;Nv.prototype.un=Nv.prototype.K;
Ht.prototype.changed=Ht.prototype.s;Ht.prototype.dispatchEvent=Ht.prototype.b;Ht.prototype.getRevision=Ht.prototype.L;Ht.prototype.on=Ht.prototype.J;Ht.prototype.once=Ht.prototype.once;Ht.prototype.un=Ht.prototype.K;Wv.prototype.changed=Wv.prototype.s;Wv.prototype.dispatchEvent=Wv.prototype.b;Wv.prototype.getRevision=Wv.prototype.L;Wv.prototype.on=Wv.prototype.J;Wv.prototype.once=Wv.prototype.once;Wv.prototype.un=Wv.prototype.K;Oh.prototype.type=Oh.prototype.type;Oh.prototype.target=Oh.prototype.target;
Oh.prototype.preventDefault=Oh.prototype.preventDefault;Oh.prototype.stopPropagation=Oh.prototype.stopPropagation;oe.prototype.type=oe.prototype.type;oe.prototype.target=oe.prototype.target;oe.prototype.preventDefault=oe.prototype.preventDefault;oe.prototype.stopPropagation=oe.prototype.stopPropagation;ph.prototype.get=ph.prototype.get;ph.prototype.getKeys=ph.prototype.P;ph.prototype.getProperties=ph.prototype.M;ph.prototype.set=ph.prototype.set;ph.prototype.setProperties=ph.prototype.H;
ph.prototype.unset=ph.prototype.R;ph.prototype.changed=ph.prototype.s;ph.prototype.dispatchEvent=ph.prototype.b;ph.prototype.getRevision=ph.prototype.L;ph.prototype.on=ph.prototype.J;ph.prototype.once=ph.prototype.once;ph.prototype.un=ph.prototype.K;rh.prototype.getExtent=rh.prototype.D;rh.prototype.getMaxResolution=rh.prototype.hc;rh.prototype.getMinResolution=rh.prototype.ic;rh.prototype.getOpacity=rh.prototype.jc;rh.prototype.getVisible=rh.prototype.Lb;rh.prototype.getZIndex=rh.prototype.Aa;
rh.prototype.setExtent=rh.prototype.xc;rh.prototype.setMaxResolution=rh.prototype.Cc;rh.prototype.setMinResolution=rh.prototype.Dc;rh.prototype.setOpacity=rh.prototype.yc;rh.prototype.setVisible=rh.prototype.zc;rh.prototype.setZIndex=rh.prototype.Xb;rh.prototype.get=rh.prototype.get;rh.prototype.getKeys=rh.prototype.P;rh.prototype.getProperties=rh.prototype.M;rh.prototype.set=rh.prototype.set;rh.prototype.setProperties=rh.prototype.H;rh.prototype.unset=rh.prototype.R;rh.prototype.changed=rh.prototype.s;
rh.prototype.dispatchEvent=rh.prototype.b;rh.prototype.getRevision=rh.prototype.L;rh.prototype.on=rh.prototype.J;rh.prototype.once=rh.prototype.once;rh.prototype.un=rh.prototype.K;th.prototype.getExtent=th.prototype.D;th.prototype.getMaxResolution=th.prototype.hc;th.prototype.getMinResolution=th.prototype.ic;th.prototype.getOpacity=th.prototype.jc;th.prototype.getVisible=th.prototype.Lb;th.prototype.getZIndex=th.prototype.Aa;th.prototype.setExtent=th.prototype.xc;th.prototype.setMaxResolution=th.prototype.Cc;
th.prototype.setMinResolution=th.prototype.Dc;th.prototype.setOpacity=th.prototype.yc;th.prototype.setVisible=th.prototype.zc;th.prototype.setZIndex=th.prototype.Xb;th.prototype.get=th.prototype.get;th.prototype.getKeys=th.prototype.P;th.prototype.getProperties=th.prototype.M;th.prototype.set=th.prototype.set;th.prototype.setProperties=th.prototype.H;th.prototype.unset=th.prototype.R;th.prototype.changed=th.prototype.s;th.prototype.dispatchEvent=th.prototype.b;th.prototype.getRevision=th.prototype.L;
th.prototype.on=th.prototype.J;th.prototype.once=th.prototype.once;th.prototype.un=th.prototype.K;S.prototype.setMap=S.prototype.setMap;S.prototype.setSource=S.prototype.ad;S.prototype.getExtent=S.prototype.D;S.prototype.getMaxResolution=S.prototype.hc;S.prototype.getMinResolution=S.prototype.ic;S.prototype.getOpacity=S.prototype.jc;S.prototype.getVisible=S.prototype.Lb;S.prototype.getZIndex=S.prototype.Aa;S.prototype.setExtent=S.prototype.xc;S.prototype.setMaxResolution=S.prototype.Cc;
S.prototype.setMinResolution=S.prototype.Dc;S.prototype.setOpacity=S.prototype.yc;S.prototype.setVisible=S.prototype.zc;S.prototype.setZIndex=S.prototype.Xb;S.prototype.get=S.prototype.get;S.prototype.getKeys=S.prototype.P;S.prototype.getProperties=S.prototype.M;S.prototype.set=S.prototype.set;S.prototype.setProperties=S.prototype.H;S.prototype.unset=S.prototype.R;S.prototype.changed=S.prototype.s;S.prototype.dispatchEvent=S.prototype.b;S.prototype.getRevision=S.prototype.L;S.prototype.on=S.prototype.J;
S.prototype.once=S.prototype.once;S.prototype.un=S.prototype.K;U.prototype.getSource=U.prototype.ka;U.prototype.getStyle=U.prototype.C;U.prototype.getStyleFunction=U.prototype.G;U.prototype.setStyle=U.prototype.f;U.prototype.setMap=U.prototype.setMap;U.prototype.setSource=U.prototype.ad;U.prototype.getExtent=U.prototype.D;U.prototype.getMaxResolution=U.prototype.hc;U.prototype.getMinResolution=U.prototype.ic;U.prototype.getOpacity=U.prototype.jc;U.prototype.getVisible=U.prototype.Lb;
U.prototype.getZIndex=U.prototype.Aa;U.prototype.setExtent=U.prototype.xc;U.prototype.setMaxResolution=U.prototype.Cc;U.prototype.setMinResolution=U.prototype.Dc;U.prototype.setOpacity=U.prototype.yc;U.prototype.setVisible=U.prototype.zc;U.prototype.setZIndex=U.prototype.Xb;U.prototype.get=U.prototype.get;U.prototype.getKeys=U.prototype.P;U.prototype.getProperties=U.prototype.M;U.prototype.set=U.prototype.set;U.prototype.setProperties=U.prototype.H;U.prototype.unset=U.prototype.R;
U.prototype.changed=U.prototype.s;U.prototype.dispatchEvent=U.prototype.b;U.prototype.getRevision=U.prototype.L;U.prototype.on=U.prototype.J;U.prototype.once=U.prototype.once;U.prototype.un=U.prototype.K;Mv.prototype.setMap=Mv.prototype.setMap;Mv.prototype.setSource=Mv.prototype.ad;Mv.prototype.getExtent=Mv.prototype.D;Mv.prototype.getMaxResolution=Mv.prototype.hc;Mv.prototype.getMinResolution=Mv.prototype.ic;Mv.prototype.getOpacity=Mv.prototype.jc;Mv.prototype.getVisible=Mv.prototype.Lb;
Mv.prototype.getZIndex=Mv.prototype.Aa;Mv.prototype.setExtent=Mv.prototype.xc;Mv.prototype.setMaxResolution=Mv.prototype.Cc;Mv.prototype.setMinResolution=Mv.prototype.Dc;Mv.prototype.setOpacity=Mv.prototype.yc;Mv.prototype.setVisible=Mv.prototype.zc;Mv.prototype.setZIndex=Mv.prototype.Xb;Mv.prototype.get=Mv.prototype.get;Mv.prototype.getKeys=Mv.prototype.P;Mv.prototype.getProperties=Mv.prototype.M;Mv.prototype.set=Mv.prototype.set;Mv.prototype.setProperties=Mv.prototype.H;Mv.prototype.unset=Mv.prototype.R;
Mv.prototype.changed=Mv.prototype.s;Mv.prototype.dispatchEvent=Mv.prototype.b;Mv.prototype.getRevision=Mv.prototype.L;Mv.prototype.on=Mv.prototype.J;Mv.prototype.once=Mv.prototype.once;Mv.prototype.un=Mv.prototype.K;Vv.prototype.setMap=Vv.prototype.setMap;Vv.prototype.setSource=Vv.prototype.ad;Vv.prototype.getExtent=Vv.prototype.D;Vv.prototype.getMaxResolution=Vv.prototype.hc;Vv.prototype.getMinResolution=Vv.prototype.ic;Vv.prototype.getOpacity=Vv.prototype.jc;Vv.prototype.getVisible=Vv.prototype.Lb;
Vv.prototype.getZIndex=Vv.prototype.Aa;Vv.prototype.setExtent=Vv.prototype.xc;Vv.prototype.setMaxResolution=Vv.prototype.Cc;Vv.prototype.setMinResolution=Vv.prototype.Dc;Vv.prototype.setOpacity=Vv.prototype.yc;Vv.prototype.setVisible=Vv.prototype.zc;Vv.prototype.setZIndex=Vv.prototype.Xb;Vv.prototype.get=Vv.prototype.get;Vv.prototype.getKeys=Vv.prototype.P;Vv.prototype.getProperties=Vv.prototype.M;Vv.prototype.set=Vv.prototype.set;Vv.prototype.setProperties=Vv.prototype.H;Vv.prototype.unset=Vv.prototype.R;
Vv.prototype.changed=Vv.prototype.s;Vv.prototype.dispatchEvent=Vv.prototype.b;Vv.prototype.getRevision=Vv.prototype.L;Vv.prototype.on=Vv.prototype.J;Vv.prototype.once=Vv.prototype.once;Vv.prototype.un=Vv.prototype.K;V.prototype.getSource=V.prototype.ka;V.prototype.getStyle=V.prototype.C;V.prototype.getStyleFunction=V.prototype.G;V.prototype.setStyle=V.prototype.f;V.prototype.setMap=V.prototype.setMap;V.prototype.setSource=V.prototype.ad;V.prototype.getExtent=V.prototype.D;
V.prototype.getMaxResolution=V.prototype.hc;V.prototype.getMinResolution=V.prototype.ic;V.prototype.getOpacity=V.prototype.jc;V.prototype.getVisible=V.prototype.Lb;V.prototype.getZIndex=V.prototype.Aa;V.prototype.setExtent=V.prototype.xc;V.prototype.setMaxResolution=V.prototype.Cc;V.prototype.setMinResolution=V.prototype.Dc;V.prototype.setOpacity=V.prototype.yc;V.prototype.setVisible=V.prototype.zc;V.prototype.setZIndex=V.prototype.Xb;V.prototype.get=V.prototype.get;V.prototype.getKeys=V.prototype.P;
V.prototype.getProperties=V.prototype.M;V.prototype.set=V.prototype.set;V.prototype.setProperties=V.prototype.H;V.prototype.unset=V.prototype.R;V.prototype.changed=V.prototype.s;V.prototype.dispatchEvent=V.prototype.b;V.prototype.getRevision=V.prototype.L;V.prototype.on=V.prototype.J;V.prototype.once=V.prototype.once;V.prototype.un=V.prototype.K;kg.prototype.get=kg.prototype.get;kg.prototype.getKeys=kg.prototype.P;kg.prototype.getProperties=kg.prototype.M;kg.prototype.set=kg.prototype.set;
kg.prototype.setProperties=kg.prototype.H;kg.prototype.unset=kg.prototype.R;kg.prototype.changed=kg.prototype.s;kg.prototype.dispatchEvent=kg.prototype.b;kg.prototype.getRevision=kg.prototype.L;kg.prototype.on=kg.prototype.J;kg.prototype.once=kg.prototype.once;kg.prototype.un=kg.prototype.K;og.prototype.getActive=og.prototype.c;og.prototype.getMap=og.prototype.i;og.prototype.setActive=og.prototype.Ia;og.prototype.get=og.prototype.get;og.prototype.getKeys=og.prototype.P;
og.prototype.getProperties=og.prototype.M;og.prototype.set=og.prototype.set;og.prototype.setProperties=og.prototype.H;og.prototype.unset=og.prototype.R;og.prototype.changed=og.prototype.s;og.prototype.dispatchEvent=og.prototype.b;og.prototype.getRevision=og.prototype.L;og.prototype.on=og.prototype.J;og.prototype.once=og.prototype.once;og.prototype.un=og.prototype.K;Ms.prototype.getActive=Ms.prototype.c;Ms.prototype.getMap=Ms.prototype.i;Ms.prototype.setActive=Ms.prototype.Ia;Ms.prototype.get=Ms.prototype.get;
Ms.prototype.getKeys=Ms.prototype.P;Ms.prototype.getProperties=Ms.prototype.M;Ms.prototype.set=Ms.prototype.set;Ms.prototype.setProperties=Ms.prototype.H;Ms.prototype.unset=Ms.prototype.R;Ms.prototype.changed=Ms.prototype.s;Ms.prototype.dispatchEvent=Ms.prototype.b;Ms.prototype.getRevision=Ms.prototype.L;Ms.prototype.on=Ms.prototype.J;Ms.prototype.once=Ms.prototype.once;Ms.prototype.un=Ms.prototype.K;Ps.prototype.type=Ps.prototype.type;Ps.prototype.target=Ps.prototype.target;
Ps.prototype.preventDefault=Ps.prototype.preventDefault;Ps.prototype.stopPropagation=Ps.prototype.stopPropagation;Ag.prototype.getActive=Ag.prototype.c;Ag.prototype.getMap=Ag.prototype.i;Ag.prototype.setActive=Ag.prototype.Ia;Ag.prototype.get=Ag.prototype.get;Ag.prototype.getKeys=Ag.prototype.P;Ag.prototype.getProperties=Ag.prototype.M;Ag.prototype.set=Ag.prototype.set;Ag.prototype.setProperties=Ag.prototype.H;Ag.prototype.unset=Ag.prototype.R;Ag.prototype.changed=Ag.prototype.s;
Ag.prototype.dispatchEvent=Ag.prototype.b;Ag.prototype.getRevision=Ag.prototype.L;Ag.prototype.on=Ag.prototype.J;Ag.prototype.once=Ag.prototype.once;Ag.prototype.un=Ag.prototype.K;Og.prototype.getActive=Og.prototype.c;Og.prototype.getMap=Og.prototype.i;Og.prototype.setActive=Og.prototype.Ia;Og.prototype.get=Og.prototype.get;Og.prototype.getKeys=Og.prototype.P;Og.prototype.getProperties=Og.prototype.M;Og.prototype.set=Og.prototype.set;Og.prototype.setProperties=Og.prototype.H;Og.prototype.unset=Og.prototype.R;
Og.prototype.changed=Og.prototype.s;Og.prototype.dispatchEvent=Og.prototype.b;Og.prototype.getRevision=Og.prototype.L;Og.prototype.on=Og.prototype.J;Og.prototype.once=Og.prototype.once;Og.prototype.un=Og.prototype.K;Tg.prototype.type=Tg.prototype.type;Tg.prototype.target=Tg.prototype.target;Tg.prototype.preventDefault=Tg.prototype.preventDefault;Tg.prototype.stopPropagation=Tg.prototype.stopPropagation;Dg.prototype.getActive=Dg.prototype.c;Dg.prototype.getMap=Dg.prototype.i;
Dg.prototype.setActive=Dg.prototype.Ia;Dg.prototype.get=Dg.prototype.get;Dg.prototype.getKeys=Dg.prototype.P;Dg.prototype.getProperties=Dg.prototype.M;Dg.prototype.set=Dg.prototype.set;Dg.prototype.setProperties=Dg.prototype.H;Dg.prototype.unset=Dg.prototype.R;Dg.prototype.changed=Dg.prototype.s;Dg.prototype.dispatchEvent=Dg.prototype.b;Dg.prototype.getRevision=Dg.prototype.L;Dg.prototype.on=Dg.prototype.J;Dg.prototype.once=Dg.prototype.once;Dg.prototype.un=Dg.prototype.K;Hg.prototype.getActive=Hg.prototype.c;
Hg.prototype.getMap=Hg.prototype.i;Hg.prototype.setActive=Hg.prototype.Ia;Hg.prototype.get=Hg.prototype.get;Hg.prototype.getKeys=Hg.prototype.P;Hg.prototype.getProperties=Hg.prototype.M;Hg.prototype.set=Hg.prototype.set;Hg.prototype.setProperties=Hg.prototype.H;Hg.prototype.unset=Hg.prototype.R;Hg.prototype.changed=Hg.prototype.s;Hg.prototype.dispatchEvent=Hg.prototype.b;Hg.prototype.getRevision=Hg.prototype.L;Hg.prototype.on=Hg.prototype.J;Hg.prototype.once=Hg.prototype.once;Hg.prototype.un=Hg.prototype.K;
Rs.prototype.getActive=Rs.prototype.c;Rs.prototype.getMap=Rs.prototype.i;Rs.prototype.setActive=Rs.prototype.Ia;Rs.prototype.get=Rs.prototype.get;Rs.prototype.getKeys=Rs.prototype.P;Rs.prototype.getProperties=Rs.prototype.M;Rs.prototype.set=Rs.prototype.set;Rs.prototype.setProperties=Rs.prototype.H;Rs.prototype.unset=Rs.prototype.R;Rs.prototype.changed=Rs.prototype.s;Rs.prototype.dispatchEvent=Rs.prototype.b;Rs.prototype.getRevision=Rs.prototype.L;Rs.prototype.on=Rs.prototype.J;
Rs.prototype.once=Rs.prototype.once;Rs.prototype.un=Rs.prototype.K;Xg.prototype.getGeometry=Xg.prototype.U;Xg.prototype.getActive=Xg.prototype.c;Xg.prototype.getMap=Xg.prototype.i;Xg.prototype.setActive=Xg.prototype.Ia;Xg.prototype.get=Xg.prototype.get;Xg.prototype.getKeys=Xg.prototype.P;Xg.prototype.getProperties=Xg.prototype.M;Xg.prototype.set=Xg.prototype.set;Xg.prototype.setProperties=Xg.prototype.H;Xg.prototype.unset=Xg.prototype.R;Xg.prototype.changed=Xg.prototype.s;
Xg.prototype.dispatchEvent=Xg.prototype.b;Xg.prototype.getRevision=Xg.prototype.L;Xg.prototype.on=Xg.prototype.J;Xg.prototype.once=Xg.prototype.once;Xg.prototype.un=Xg.prototype.K;cu.prototype.getActive=cu.prototype.c;cu.prototype.getMap=cu.prototype.i;cu.prototype.setActive=cu.prototype.Ia;cu.prototype.get=cu.prototype.get;cu.prototype.getKeys=cu.prototype.P;cu.prototype.getProperties=cu.prototype.M;cu.prototype.set=cu.prototype.set;cu.prototype.setProperties=cu.prototype.H;cu.prototype.unset=cu.prototype.R;
cu.prototype.changed=cu.prototype.s;cu.prototype.dispatchEvent=cu.prototype.b;cu.prototype.getRevision=cu.prototype.L;cu.prototype.on=cu.prototype.J;cu.prototype.once=cu.prototype.once;cu.prototype.un=cu.prototype.K;su.prototype.type=su.prototype.type;su.prototype.target=su.prototype.target;su.prototype.preventDefault=su.prototype.preventDefault;su.prototype.stopPropagation=su.prototype.stopPropagation;tu.prototype.getActive=tu.prototype.c;tu.prototype.getMap=tu.prototype.i;
tu.prototype.setActive=tu.prototype.Ia;tu.prototype.get=tu.prototype.get;tu.prototype.getKeys=tu.prototype.P;tu.prototype.getProperties=tu.prototype.M;tu.prototype.set=tu.prototype.set;tu.prototype.setProperties=tu.prototype.H;tu.prototype.unset=tu.prototype.R;tu.prototype.changed=tu.prototype.s;tu.prototype.dispatchEvent=tu.prototype.b;tu.prototype.getRevision=tu.prototype.L;tu.prototype.on=tu.prototype.J;tu.prototype.once=tu.prototype.once;tu.prototype.un=tu.prototype.K;Eu.prototype.type=Eu.prototype.type;
Eu.prototype.target=Eu.prototype.target;Eu.prototype.preventDefault=Eu.prototype.preventDefault;Eu.prototype.stopPropagation=Eu.prototype.stopPropagation;Yg.prototype.getActive=Yg.prototype.c;Yg.prototype.getMap=Yg.prototype.i;Yg.prototype.setActive=Yg.prototype.Ia;Yg.prototype.get=Yg.prototype.get;Yg.prototype.getKeys=Yg.prototype.P;Yg.prototype.getProperties=Yg.prototype.M;Yg.prototype.set=Yg.prototype.set;Yg.prototype.setProperties=Yg.prototype.H;Yg.prototype.unset=Yg.prototype.R;
Yg.prototype.changed=Yg.prototype.s;Yg.prototype.dispatchEvent=Yg.prototype.b;Yg.prototype.getRevision=Yg.prototype.L;Yg.prototype.on=Yg.prototype.J;Yg.prototype.once=Yg.prototype.once;Yg.prototype.un=Yg.prototype.K;$g.prototype.getActive=$g.prototype.c;$g.prototype.getMap=$g.prototype.i;$g.prototype.setActive=$g.prototype.Ia;$g.prototype.get=$g.prototype.get;$g.prototype.getKeys=$g.prototype.P;$g.prototype.getProperties=$g.prototype.M;$g.prototype.set=$g.prototype.set;
$g.prototype.setProperties=$g.prototype.H;$g.prototype.unset=$g.prototype.R;$g.prototype.changed=$g.prototype.s;$g.prototype.dispatchEvent=$g.prototype.b;$g.prototype.getRevision=$g.prototype.L;$g.prototype.on=$g.prototype.J;$g.prototype.once=$g.prototype.once;$g.prototype.un=$g.prototype.K;Gu.prototype.getActive=Gu.prototype.c;Gu.prototype.getMap=Gu.prototype.i;Gu.prototype.setActive=Gu.prototype.Ia;Gu.prototype.get=Gu.prototype.get;Gu.prototype.getKeys=Gu.prototype.P;
Gu.prototype.getProperties=Gu.prototype.M;Gu.prototype.set=Gu.prototype.set;Gu.prototype.setProperties=Gu.prototype.H;Gu.prototype.unset=Gu.prototype.R;Gu.prototype.changed=Gu.prototype.s;Gu.prototype.dispatchEvent=Gu.prototype.b;Gu.prototype.getRevision=Gu.prototype.L;Gu.prototype.on=Gu.prototype.J;Gu.prototype.once=Gu.prototype.once;Gu.prototype.un=Gu.prototype.K;Ou.prototype.type=Ou.prototype.type;Ou.prototype.target=Ou.prototype.target;Ou.prototype.preventDefault=Ou.prototype.preventDefault;
Ou.prototype.stopPropagation=Ou.prototype.stopPropagation;bh.prototype.getActive=bh.prototype.c;bh.prototype.getMap=bh.prototype.i;bh.prototype.setActive=bh.prototype.Ia;bh.prototype.get=bh.prototype.get;bh.prototype.getKeys=bh.prototype.P;bh.prototype.getProperties=bh.prototype.M;bh.prototype.set=bh.prototype.set;bh.prototype.setProperties=bh.prototype.H;bh.prototype.unset=bh.prototype.R;bh.prototype.changed=bh.prototype.s;bh.prototype.dispatchEvent=bh.prototype.b;bh.prototype.getRevision=bh.prototype.L;
bh.prototype.on=bh.prototype.J;bh.prototype.once=bh.prototype.once;bh.prototype.un=bh.prototype.K;fh.prototype.getActive=fh.prototype.c;fh.prototype.getMap=fh.prototype.i;fh.prototype.setActive=fh.prototype.Ia;fh.prototype.get=fh.prototype.get;fh.prototype.getKeys=fh.prototype.P;fh.prototype.getProperties=fh.prototype.M;fh.prototype.set=fh.prototype.set;fh.prototype.setProperties=fh.prototype.H;fh.prototype.unset=fh.prototype.R;fh.prototype.changed=fh.prototype.s;fh.prototype.dispatchEvent=fh.prototype.b;
fh.prototype.getRevision=fh.prototype.L;fh.prototype.on=fh.prototype.J;fh.prototype.once=fh.prototype.once;fh.prototype.un=fh.prototype.K;jh.prototype.getActive=jh.prototype.c;jh.prototype.getMap=jh.prototype.i;jh.prototype.setActive=jh.prototype.Ia;jh.prototype.get=jh.prototype.get;jh.prototype.getKeys=jh.prototype.P;jh.prototype.getProperties=jh.prototype.M;jh.prototype.set=jh.prototype.set;jh.prototype.setProperties=jh.prototype.H;jh.prototype.unset=jh.prototype.R;jh.prototype.changed=jh.prototype.s;
jh.prototype.dispatchEvent=jh.prototype.b;jh.prototype.getRevision=jh.prototype.L;jh.prototype.on=jh.prototype.J;jh.prototype.once=jh.prototype.once;jh.prototype.un=jh.prototype.K;Wu.prototype.getActive=Wu.prototype.c;Wu.prototype.getMap=Wu.prototype.i;Wu.prototype.setActive=Wu.prototype.Ia;Wu.prototype.get=Wu.prototype.get;Wu.prototype.getKeys=Wu.prototype.P;Wu.prototype.getProperties=Wu.prototype.M;Wu.prototype.set=Wu.prototype.set;Wu.prototype.setProperties=Wu.prototype.H;Wu.prototype.unset=Wu.prototype.R;
Wu.prototype.changed=Wu.prototype.s;Wu.prototype.dispatchEvent=Wu.prototype.b;Wu.prototype.getRevision=Wu.prototype.L;Wu.prototype.on=Wu.prototype.J;Wu.prototype.once=Wu.prototype.once;Wu.prototype.un=Wu.prototype.K;Zu.prototype.type=Zu.prototype.type;Zu.prototype.target=Zu.prototype.target;Zu.prototype.preventDefault=Zu.prototype.preventDefault;Zu.prototype.stopPropagation=Zu.prototype.stopPropagation;av.prototype.getActive=av.prototype.c;av.prototype.getMap=av.prototype.i;
av.prototype.setActive=av.prototype.Ia;av.prototype.get=av.prototype.get;av.prototype.getKeys=av.prototype.P;av.prototype.getProperties=av.prototype.M;av.prototype.set=av.prototype.set;av.prototype.setProperties=av.prototype.H;av.prototype.unset=av.prototype.R;av.prototype.changed=av.prototype.s;av.prototype.dispatchEvent=av.prototype.b;av.prototype.getRevision=av.prototype.L;av.prototype.on=av.prototype.J;av.prototype.once=av.prototype.once;av.prototype.un=av.prototype.K;ev.prototype.getActive=ev.prototype.c;
ev.prototype.getMap=ev.prototype.i;ev.prototype.setActive=ev.prototype.Ia;ev.prototype.get=ev.prototype.get;ev.prototype.getKeys=ev.prototype.P;ev.prototype.getProperties=ev.prototype.M;ev.prototype.set=ev.prototype.set;ev.prototype.setProperties=ev.prototype.H;ev.prototype.unset=ev.prototype.R;ev.prototype.changed=ev.prototype.s;ev.prototype.dispatchEvent=ev.prototype.b;ev.prototype.getRevision=ev.prototype.L;ev.prototype.on=ev.prototype.J;ev.prototype.once=ev.prototype.once;ev.prototype.un=ev.prototype.K;
kv.prototype.type=kv.prototype.type;kv.prototype.target=kv.prototype.target;kv.prototype.preventDefault=kv.prototype.preventDefault;kv.prototype.stopPropagation=kv.prototype.stopPropagation;lf.prototype.get=lf.prototype.get;lf.prototype.getKeys=lf.prototype.P;lf.prototype.getProperties=lf.prototype.M;lf.prototype.set=lf.prototype.set;lf.prototype.setProperties=lf.prototype.H;lf.prototype.unset=lf.prototype.R;lf.prototype.changed=lf.prototype.s;lf.prototype.dispatchEvent=lf.prototype.b;
lf.prototype.getRevision=lf.prototype.L;lf.prototype.on=lf.prototype.J;lf.prototype.once=lf.prototype.once;lf.prototype.un=lf.prototype.K;of.prototype.getClosestPoint=of.prototype.Ab;of.prototype.intersectsCoordinate=of.prototype.sb;of.prototype.getExtent=of.prototype.D;of.prototype.rotate=of.prototype.rotate;of.prototype.scale=of.prototype.scale;of.prototype.simplify=of.prototype.Qb;of.prototype.transform=of.prototype.tb;of.prototype.get=of.prototype.get;of.prototype.getKeys=of.prototype.P;
of.prototype.getProperties=of.prototype.M;of.prototype.set=of.prototype.set;of.prototype.setProperties=of.prototype.H;of.prototype.unset=of.prototype.R;of.prototype.changed=of.prototype.s;of.prototype.dispatchEvent=of.prototype.b;of.prototype.getRevision=of.prototype.L;of.prototype.on=of.prototype.J;of.prototype.once=of.prototype.once;of.prototype.un=of.prototype.K;vs.prototype.getFirstCoordinate=vs.prototype.cc;vs.prototype.getLastCoordinate=vs.prototype.dc;vs.prototype.getLayout=vs.prototype.ec;
vs.prototype.rotate=vs.prototype.rotate;vs.prototype.scale=vs.prototype.scale;vs.prototype.getClosestPoint=vs.prototype.Ab;vs.prototype.intersectsCoordinate=vs.prototype.sb;vs.prototype.getExtent=vs.prototype.D;vs.prototype.simplify=vs.prototype.Qb;vs.prototype.get=vs.prototype.get;vs.prototype.getKeys=vs.prototype.P;vs.prototype.getProperties=vs.prototype.M;vs.prototype.set=vs.prototype.set;vs.prototype.setProperties=vs.prototype.H;vs.prototype.unset=vs.prototype.R;vs.prototype.changed=vs.prototype.s;
vs.prototype.dispatchEvent=vs.prototype.b;vs.prototype.getRevision=vs.prototype.L;vs.prototype.on=vs.prototype.J;vs.prototype.once=vs.prototype.once;vs.prototype.un=vs.prototype.K;sm.prototype.getClosestPoint=sm.prototype.Ab;sm.prototype.intersectsCoordinate=sm.prototype.sb;sm.prototype.getExtent=sm.prototype.D;sm.prototype.rotate=sm.prototype.rotate;sm.prototype.scale=sm.prototype.scale;sm.prototype.simplify=sm.prototype.Qb;sm.prototype.transform=sm.prototype.tb;sm.prototype.get=sm.prototype.get;
sm.prototype.getKeys=sm.prototype.P;sm.prototype.getProperties=sm.prototype.M;sm.prototype.set=sm.prototype.set;sm.prototype.setProperties=sm.prototype.H;sm.prototype.unset=sm.prototype.R;sm.prototype.changed=sm.prototype.s;sm.prototype.dispatchEvent=sm.prototype.b;sm.prototype.getRevision=sm.prototype.L;sm.prototype.on=sm.prototype.J;sm.prototype.once=sm.prototype.once;sm.prototype.un=sm.prototype.K;Gf.prototype.getFirstCoordinate=Gf.prototype.cc;Gf.prototype.getLastCoordinate=Gf.prototype.dc;
Gf.prototype.getLayout=Gf.prototype.ec;Gf.prototype.rotate=Gf.prototype.rotate;Gf.prototype.scale=Gf.prototype.scale;Gf.prototype.getClosestPoint=Gf.prototype.Ab;Gf.prototype.intersectsCoordinate=Gf.prototype.sb;Gf.prototype.getExtent=Gf.prototype.D;Gf.prototype.simplify=Gf.prototype.Qb;Gf.prototype.transform=Gf.prototype.tb;Gf.prototype.get=Gf.prototype.get;Gf.prototype.getKeys=Gf.prototype.P;Gf.prototype.getProperties=Gf.prototype.M;Gf.prototype.set=Gf.prototype.set;Gf.prototype.setProperties=Gf.prototype.H;
Gf.prototype.unset=Gf.prototype.R;Gf.prototype.changed=Gf.prototype.s;Gf.prototype.dispatchEvent=Gf.prototype.b;Gf.prototype.getRevision=Gf.prototype.L;Gf.prototype.on=Gf.prototype.J;Gf.prototype.once=Gf.prototype.once;Gf.prototype.un=Gf.prototype.K;N.prototype.getFirstCoordinate=N.prototype.cc;N.prototype.getLastCoordinate=N.prototype.dc;N.prototype.getLayout=N.prototype.ec;N.prototype.rotate=N.prototype.rotate;N.prototype.scale=N.prototype.scale;N.prototype.getClosestPoint=N.prototype.Ab;
N.prototype.intersectsCoordinate=N.prototype.sb;N.prototype.getExtent=N.prototype.D;N.prototype.simplify=N.prototype.Qb;N.prototype.transform=N.prototype.tb;N.prototype.get=N.prototype.get;N.prototype.getKeys=N.prototype.P;N.prototype.getProperties=N.prototype.M;N.prototype.set=N.prototype.set;N.prototype.setProperties=N.prototype.H;N.prototype.unset=N.prototype.R;N.prototype.changed=N.prototype.s;N.prototype.dispatchEvent=N.prototype.b;N.prototype.getRevision=N.prototype.L;N.prototype.on=N.prototype.J;
N.prototype.once=N.prototype.once;N.prototype.un=N.prototype.K;O.prototype.getFirstCoordinate=O.prototype.cc;O.prototype.getLastCoordinate=O.prototype.dc;O.prototype.getLayout=O.prototype.ec;O.prototype.rotate=O.prototype.rotate;O.prototype.scale=O.prototype.scale;O.prototype.getClosestPoint=O.prototype.Ab;O.prototype.intersectsCoordinate=O.prototype.sb;O.prototype.getExtent=O.prototype.D;O.prototype.simplify=O.prototype.Qb;O.prototype.transform=O.prototype.tb;O.prototype.get=O.prototype.get;
O.prototype.getKeys=O.prototype.P;O.prototype.getProperties=O.prototype.M;O.prototype.set=O.prototype.set;O.prototype.setProperties=O.prototype.H;O.prototype.unset=O.prototype.R;O.prototype.changed=O.prototype.s;O.prototype.dispatchEvent=O.prototype.b;O.prototype.getRevision=O.prototype.L;O.prototype.on=O.prototype.J;O.prototype.once=O.prototype.once;O.prototype.un=O.prototype.K;P.prototype.getFirstCoordinate=P.prototype.cc;P.prototype.getLastCoordinate=P.prototype.dc;P.prototype.getLayout=P.prototype.ec;
P.prototype.rotate=P.prototype.rotate;P.prototype.scale=P.prototype.scale;P.prototype.getClosestPoint=P.prototype.Ab;P.prototype.intersectsCoordinate=P.prototype.sb;P.prototype.getExtent=P.prototype.D;P.prototype.simplify=P.prototype.Qb;P.prototype.transform=P.prototype.tb;P.prototype.get=P.prototype.get;P.prototype.getKeys=P.prototype.P;P.prototype.getProperties=P.prototype.M;P.prototype.set=P.prototype.set;P.prototype.setProperties=P.prototype.H;P.prototype.unset=P.prototype.R;
P.prototype.changed=P.prototype.s;P.prototype.dispatchEvent=P.prototype.b;P.prototype.getRevision=P.prototype.L;P.prototype.on=P.prototype.J;P.prototype.once=P.prototype.once;P.prototype.un=P.prototype.K;Q.prototype.getFirstCoordinate=Q.prototype.cc;Q.prototype.getLastCoordinate=Q.prototype.dc;Q.prototype.getLayout=Q.prototype.ec;Q.prototype.rotate=Q.prototype.rotate;Q.prototype.scale=Q.prototype.scale;Q.prototype.getClosestPoint=Q.prototype.Ab;Q.prototype.intersectsCoordinate=Q.prototype.sb;
Q.prototype.getExtent=Q.prototype.D;Q.prototype.simplify=Q.prototype.Qb;Q.prototype.transform=Q.prototype.tb;Q.prototype.get=Q.prototype.get;Q.prototype.getKeys=Q.prototype.P;Q.prototype.getProperties=Q.prototype.M;Q.prototype.set=Q.prototype.set;Q.prototype.setProperties=Q.prototype.H;Q.prototype.unset=Q.prototype.R;Q.prototype.changed=Q.prototype.s;Q.prototype.dispatchEvent=Q.prototype.b;Q.prototype.getRevision=Q.prototype.L;Q.prototype.on=Q.prototype.J;Q.prototype.once=Q.prototype.once;
Q.prototype.un=Q.prototype.K;E.prototype.getFirstCoordinate=E.prototype.cc;E.prototype.getLastCoordinate=E.prototype.dc;E.prototype.getLayout=E.prototype.ec;E.prototype.rotate=E.prototype.rotate;E.prototype.scale=E.prototype.scale;E.prototype.getClosestPoint=E.prototype.Ab;E.prototype.intersectsCoordinate=E.prototype.sb;E.prototype.getExtent=E.prototype.D;E.prototype.simplify=E.prototype.Qb;E.prototype.transform=E.prototype.tb;E.prototype.get=E.prototype.get;E.prototype.getKeys=E.prototype.P;
E.prototype.getProperties=E.prototype.M;E.prototype.set=E.prototype.set;E.prototype.setProperties=E.prototype.H;E.prototype.unset=E.prototype.R;E.prototype.changed=E.prototype.s;E.prototype.dispatchEvent=E.prototype.b;E.prototype.getRevision=E.prototype.L;E.prototype.on=E.prototype.J;E.prototype.once=E.prototype.once;E.prototype.un=E.prototype.K;F.prototype.getFirstCoordinate=F.prototype.cc;F.prototype.getLastCoordinate=F.prototype.dc;F.prototype.getLayout=F.prototype.ec;F.prototype.rotate=F.prototype.rotate;
F.prototype.scale=F.prototype.scale;F.prototype.getClosestPoint=F.prototype.Ab;F.prototype.intersectsCoordinate=F.prototype.sb;F.prototype.getExtent=F.prototype.D;F.prototype.simplify=F.prototype.Qb;F.prototype.transform=F.prototype.tb;F.prototype.get=F.prototype.get;F.prototype.getKeys=F.prototype.P;F.prototype.getProperties=F.prototype.M;F.prototype.set=F.prototype.set;F.prototype.setProperties=F.prototype.H;F.prototype.unset=F.prototype.R;F.prototype.changed=F.prototype.s;
F.prototype.dispatchEvent=F.prototype.b;F.prototype.getRevision=F.prototype.L;F.prototype.on=F.prototype.J;F.prototype.once=F.prototype.once;F.prototype.un=F.prototype.K;Rm.prototype.readFeatures=Rm.prototype.Pa;$m.prototype.readFeatures=$m.prototype.Pa;Rm.prototype.readFeatures=Rm.prototype.Pa;kd.prototype.get=kd.prototype.get;kd.prototype.getKeys=kd.prototype.P;kd.prototype.getProperties=kd.prototype.M;kd.prototype.set=kd.prototype.set;kd.prototype.setProperties=kd.prototype.H;
kd.prototype.unset=kd.prototype.R;kd.prototype.changed=kd.prototype.s;kd.prototype.dispatchEvent=kd.prototype.b;kd.prototype.getRevision=kd.prototype.L;kd.prototype.on=kd.prototype.J;kd.prototype.once=kd.prototype.once;kd.prototype.un=kd.prototype.K;ld.prototype.getMap=ld.prototype.f;ld.prototype.setMap=ld.prototype.setMap;ld.prototype.setTarget=ld.prototype.i;ld.prototype.get=ld.prototype.get;ld.prototype.getKeys=ld.prototype.P;ld.prototype.getProperties=ld.prototype.M;ld.prototype.set=ld.prototype.set;
ld.prototype.setProperties=ld.prototype.H;ld.prototype.unset=ld.prototype.R;ld.prototype.changed=ld.prototype.s;ld.prototype.dispatchEvent=ld.prototype.b;ld.prototype.getRevision=ld.prototype.L;ld.prototype.on=ld.prototype.J;ld.prototype.once=ld.prototype.once;ld.prototype.un=ld.prototype.K;wd.prototype.getMap=wd.prototype.f;wd.prototype.setMap=wd.prototype.setMap;wd.prototype.setTarget=wd.prototype.i;wd.prototype.get=wd.prototype.get;wd.prototype.getKeys=wd.prototype.P;
wd.prototype.getProperties=wd.prototype.M;wd.prototype.set=wd.prototype.set;wd.prototype.setProperties=wd.prototype.H;wd.prototype.unset=wd.prototype.R;wd.prototype.changed=wd.prototype.s;wd.prototype.dispatchEvent=wd.prototype.b;wd.prototype.getRevision=wd.prototype.L;wd.prototype.on=wd.prototype.J;wd.prototype.once=wd.prototype.once;wd.prototype.un=wd.prototype.K;Bd.prototype.getMap=Bd.prototype.f;Bd.prototype.setMap=Bd.prototype.setMap;Bd.prototype.setTarget=Bd.prototype.i;Bd.prototype.get=Bd.prototype.get;
Bd.prototype.getKeys=Bd.prototype.P;Bd.prototype.getProperties=Bd.prototype.M;Bd.prototype.set=Bd.prototype.set;Bd.prototype.setProperties=Bd.prototype.H;Bd.prototype.unset=Bd.prototype.R;Bd.prototype.changed=Bd.prototype.s;Bd.prototype.dispatchEvent=Bd.prototype.b;Bd.prototype.getRevision=Bd.prototype.L;Bd.prototype.on=Bd.prototype.J;Bd.prototype.once=Bd.prototype.once;Bd.prototype.un=Bd.prototype.K;Bk.prototype.getMap=Bk.prototype.f;Bk.prototype.setMap=Bk.prototype.setMap;
Bk.prototype.setTarget=Bk.prototype.i;Bk.prototype.get=Bk.prototype.get;Bk.prototype.getKeys=Bk.prototype.P;Bk.prototype.getProperties=Bk.prototype.M;Bk.prototype.set=Bk.prototype.set;Bk.prototype.setProperties=Bk.prototype.H;Bk.prototype.unset=Bk.prototype.R;Bk.prototype.changed=Bk.prototype.s;Bk.prototype.dispatchEvent=Bk.prototype.b;Bk.prototype.getRevision=Bk.prototype.L;Bk.prototype.on=Bk.prototype.J;Bk.prototype.once=Bk.prototype.once;Bk.prototype.un=Bk.prototype.K;sd.prototype.getMap=sd.prototype.f;
sd.prototype.setMap=sd.prototype.setMap;sd.prototype.setTarget=sd.prototype.i;sd.prototype.get=sd.prototype.get;sd.prototype.getKeys=sd.prototype.P;sd.prototype.getProperties=sd.prototype.M;sd.prototype.set=sd.prototype.set;sd.prototype.setProperties=sd.prototype.H;sd.prototype.unset=sd.prototype.R;sd.prototype.changed=sd.prototype.s;sd.prototype.dispatchEvent=sd.prototype.b;sd.prototype.getRevision=sd.prototype.L;sd.prototype.on=sd.prototype.J;sd.prototype.once=sd.prototype.once;
sd.prototype.un=sd.prototype.K;Gk.prototype.getMap=Gk.prototype.f;Gk.prototype.setMap=Gk.prototype.setMap;Gk.prototype.setTarget=Gk.prototype.i;Gk.prototype.get=Gk.prototype.get;Gk.prototype.getKeys=Gk.prototype.P;Gk.prototype.getProperties=Gk.prototype.M;Gk.prototype.set=Gk.prototype.set;Gk.prototype.setProperties=Gk.prototype.H;Gk.prototype.unset=Gk.prototype.R;Gk.prototype.changed=Gk.prototype.s;Gk.prototype.dispatchEvent=Gk.prototype.b;Gk.prototype.getRevision=Gk.prototype.L;Gk.prototype.on=Gk.prototype.J;
Gk.prototype.once=Gk.prototype.once;Gk.prototype.un=Gk.prototype.K;ud.prototype.getMap=ud.prototype.f;ud.prototype.setMap=ud.prototype.setMap;ud.prototype.setTarget=ud.prototype.i;ud.prototype.get=ud.prototype.get;ud.prototype.getKeys=ud.prototype.P;ud.prototype.getProperties=ud.prototype.M;ud.prototype.set=ud.prototype.set;ud.prototype.setProperties=ud.prototype.H;ud.prototype.unset=ud.prototype.R;ud.prototype.changed=ud.prototype.s;ud.prototype.dispatchEvent=ud.prototype.b;
ud.prototype.getRevision=ud.prototype.L;ud.prototype.on=ud.prototype.J;ud.prototype.once=ud.prototype.once;ud.prototype.un=ud.prototype.K;Lk.prototype.getMap=Lk.prototype.f;Lk.prototype.setMap=Lk.prototype.setMap;Lk.prototype.setTarget=Lk.prototype.i;Lk.prototype.get=Lk.prototype.get;Lk.prototype.getKeys=Lk.prototype.P;Lk.prototype.getProperties=Lk.prototype.M;Lk.prototype.set=Lk.prototype.set;Lk.prototype.setProperties=Lk.prototype.H;Lk.prototype.unset=Lk.prototype.R;Lk.prototype.changed=Lk.prototype.s;
Lk.prototype.dispatchEvent=Lk.prototype.b;Lk.prototype.getRevision=Lk.prototype.L;Lk.prototype.on=Lk.prototype.J;Lk.prototype.once=Lk.prototype.once;Lk.prototype.un=Lk.prototype.K;Qk.prototype.getMap=Qk.prototype.f;Qk.prototype.setMap=Qk.prototype.setMap;Qk.prototype.setTarget=Qk.prototype.i;Qk.prototype.get=Qk.prototype.get;Qk.prototype.getKeys=Qk.prototype.P;Qk.prototype.getProperties=Qk.prototype.M;Qk.prototype.set=Qk.prototype.set;Qk.prototype.setProperties=Qk.prototype.H;Qk.prototype.unset=Qk.prototype.R;
Qk.prototype.changed=Qk.prototype.s;Qk.prototype.dispatchEvent=Qk.prototype.b;Qk.prototype.getRevision=Qk.prototype.L;Qk.prototype.on=Qk.prototype.J;Qk.prototype.once=Qk.prototype.once;Qk.prototype.un=Qk.prototype.K;
  return OPENLAYERS.ol;
}));
 
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/

Statements: 11.63% (155 / 1333)      Branches: 100% (0 / 0)      Functions: 0% (0 / 293)      Lines: 11.63% (155 / 1333)      Ignored: none     

All files » node-npmtest-openlayers/node_modules/openlayers/externs/
File Statements Branches Functions Lines
bingmaps.js 100% (28 / 28) 100% (0 / 0) 0% (0 / 5) 100% (28 / 28)
bootstrap.js 50% (1 / 2) 100% (0 / 0) 0% (0 / 2) 50% (1 / 2)
cartodb.js 100% (5 / 5) 100% (0 / 0) 0% (0 / 1) 100% (5 / 5)
closure-compiler.js 100% (0 / 0) 100% (0 / 0) 100% (0 / 0) 100% (0 / 0)
esrijson.js 100% (28 / 28) 100% (0 / 0) 0% (0 / 8) 100% (28 / 28)
geojson.js 100% (24 / 24) 100% (0 / 0) 0% (0 / 9) 100% (24 / 24)
jquery-1.9.js 5.42% (16 / 295) 100% (0 / 0) 0% (0 / 231) 5.42% (16 / 295)
oli.js 3.23% (2 / 62) 100% (0 / 0) 0% (0 / 21) 3.23% (2 / 62)
olx.js 0.24% (2 / 840) 100% (0 / 0) 100% (0 / 0) 0.24% (2 / 840)
proj4js.js 100% (5 / 5) 100% (0 / 0) 0% (0 / 4) 100% (5 / 5)
tilejson.js 100% (19 / 19) 100% (0 / 0) 0% (0 / 2) 100% (19 / 19)
topojson.js 100% (25 / 25) 100% (0 / 0) 0% (0 / 10) 100% (25 / 25)
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/bingmaps.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/bingmaps.js

Statements: 100% (28 / 28)      Branches: 100% (0 / 0)      Functions: 0% (0 / 5)      Lines: 100% (28 / 28)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178                  1           1           1           1             1           1           1             1           1           1           1           1           1           1           1             1           1           1           1           1           1           1           1           1           1             1           1           1    
/**
 * @externs
 */
 
 
 
/**
 * @constructor
 */
var BingMapsCoverageArea = function() {};
 
 
/**
 * @type {Array.<number>}
 */
BingMapsCoverageArea.prototype.bbox;
 
 
/**
 * @type {number}
 */
BingMapsCoverageArea.prototype.zoomMax;
 
 
/**
 * @type {number}
 */
BingMapsCoverageArea.prototype.zoomMin;
 
 
 
/**
 * @constructor
 */
var BingMapsImageryProvider = function() {};
 
 
/**
 * @type {string}
 */
BingMapsImageryProvider.prototype.attribution;
 
 
/**
 * @type {Array.<BingMapsCoverageArea>}
 */
BingMapsImageryProvider.prototype.coverageAreas;
 
 
 
/**
 * @constructor
 */
var BingMapsImageryMetadataResponse = function() {};
 
 
/**
 * @type {string}
 */
BingMapsImageryMetadataResponse.prototype.authenticationResultCode;
 
 
/**
 * @type {string}
 */
BingMapsImageryMetadataResponse.prototype.brandLogoUri;
 
 
/**
 * @type {string}
 */
BingMapsImageryMetadataResponse.prototype.copyright;
 
 
/**
 * @type {Array.<BingMapsResourceSet>}
 */
BingMapsImageryMetadataResponse.prototype.resourceSets;
 
 
/**
 * @type {number}
 */
BingMapsImageryMetadataResponse.prototype.statusCode;
 
 
/**
 * @type {string}
 */
BingMapsImageryMetadataResponse.prototype.statusDescription;
 
 
/**
 * @type {string}
 */
BingMapsImageryMetadataResponse.prototype.traceId;
 
 
 
/**
 * @constructor
 */
var BingMapsResource = function() {};
 
 
/**
 * @type {number}
 */
BingMapsResource.prototype.imageHeight;
 
 
/**
 * @type {string}
 */
BingMapsResource.prototype.imageUrl;
 
 
/**
 * @type {Array.<string>}
 */
BingMapsResource.prototype.imageUrlSubdomains;
 
 
/**
 * @type {number}
 */
BingMapsResource.prototype.imageWidth;
 
 
/**
 * @type {Array.<BingMapsImageryProvider>}
 */
BingMapsResource.prototype.imageryProviders;
 
 
/**
 * @type {Object}
 */
BingMapsResource.prototype.vintageEnd;
 
 
/**
 * @type {Object}
 */
BingMapsResource.prototype.vintageStart;
 
 
/**
 * @type {number}
 */
BingMapsResource.prototype.zoomMax;
 
 
/**
 * @type {number}
 */
BingMapsResource.prototype.zoomMin;
 
 
 
/**
 * @constructor
 */
var BingMapsResourceSet = function() {};
 
 
/**
 * @type {number}
 */
BingMapsResourceSet.prototype.estimatedTotal;
 
 
/**
 * @type {Array.<BingMapsResource>}
 */
BingMapsResourceSet.prototype.resources;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/bootstrap.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/bootstrap.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 0% (0 / 2)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22                        2                  
/**
 * @fileoverview Externs for bootstrap.js
 *
 * @see http://twitter.github.com/bootstrap/javascript.html
 * @externs
 */
 
 
/**
 * @param {string|Object.<string,*>=} opt_option
 * @return {!jQuery}
 */
jQuery.prototype.popover = function(opt_option) {};
 
 
/**
 * @param {string|Object.<string,*>=} opt_option
 * @return {!jQuery}
 */
jQuery.prototype.tooltip = function(opt_option) {};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/cartodb.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/cartodb.js

Statements: 100% (5 / 5)      Branches: 100% (0 / 0)      Functions: 0% (0 / 1)      Lines: 100% (5 / 5)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36                  1           1           1           1           1    
/**
 * @externs
 */
 
 
 
/**
 * @constructor
 */
var CartoDBLayerInfo = function() {};
 
 
/**
 * @type {string}
 */
CartoDBLayerInfo.prototype.layergroupid;
 
 
/**
 * @type {string}
 */
CartoDBLayerInfo.prototype.updated_at;
 
 
/**
 * @type {Object}
 */
CartoDBLayerInfo.prototype.metadata;
 
 
/**
 * @type {{http: string, https: string}}
 */
CartoDBLayerInfo.prototype.cdn_url;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/closure-compiler.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/closure-compiler.js

Statements: 100% (0 / 0)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 100% (0 / 0)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11                     
/**
 * @fileoverview Definitions for externs that are either missing or incorrect
 * in the current release version of the closure compiler we use.
 *
 * The entries must be removed once they are available/correct in the
 * version we use.
 *
 * @externs
 */
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/esrijson.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/esrijson.js

Statements: 100% (28 / 28)      Branches: 100% (0 / 0)      Functions: 0% (0 / 8)      Lines: 100% (28 / 28)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200                        1           1             1             1               1             1             1               1             1             1             1             1           1             1             1             1           1             1             1             1           1             1             1           1           1               1           1             1    
 
/**
 * @fileoverview Externs for EsriJSON.
 * @see http://resources.arcgis.com/en/help/rest/apiref/geometry.html
 * @externs
 */
 
 
 
/**
 * @constructor
 */
var EsriJSONObject = function() {};
 
 
/**
 * @type {!EsriJSONCRS}
 */
EsriJSONObject.prototype.spatialReference;
 
 
 
/**
 * @constructor
 */
var EsriJSONCRS = function() {};
 
 
/**
 * CRS well know identifier.
 * @type {number}
 */
EsriJSONCRS.prototype.wkid;
 
 
 
/**
 * @constructor
 * @extends {EsriJSONObject}
 */
var EsriJSONPoint = function() {};
 
 
/**
 * M value of point.
 * @type {number}
 */
EsriJSONPoint.prototype.m;
 
 
/**
 * X coordinate of point.
 * @type {number}
 */
EsriJSONPoint.prototype.x;
 
 
 
/**
 * Y coordinate of point.
 * @type {number}
 */
EsriJSONPoint.prototype.y;
 
 
/**
 * Z coordinate of point.
 * @type {number|undefined}
 */
EsriJSONPoint.prototype.z;
 
 
/**
 * @constructor
 * @extends {EsriJSONObject}
 */
var EsriJSONMultipoint = function() {};
 
 
/**
 * Does Multipoint have M values?
 * @type {boolean|undefined}
 */
EsriJSONMultipoint.prototype.hasM;
 
 
/**
 * Does Multipoint have Z values?
 * @type {boolean|undefined}
 */
EsriJSONMultipoint.prototype.hasZ;
 
 
/**
 * @type {!Array.<!Array.<number>>}
 */
EsriJSONMultipoint.prototype.points;
 
 
/**
 * @constructor
 * @extends {EsriJSONObject}
 */
var EsriJSONPolyline = function() {};
 
 
/**
 * Does Polyline have M values?
 * @type {boolean|undefined}
 */
EsriJSONPolyline.prototype.hasM;
 
 
/**
 * Does Polyline have Z values?
 * @type {boolean|undefined}
 */
EsriJSONPolyline.prototype.hasZ;
 
 
/**
 * @type {!Array.<!Array.<!Array.<number>>>}
 */
EsriJSONPolyline.prototype.paths;
 
 
/**
 * @constructor
 * @extends {EsriJSONObject}
 */
var EsriJSONPolygon = function() {};
 
 
/**
 * Does Polygon have M values?
 * @type {boolean|undefined}
 */
EsriJSONPolygon.prototype.hasM;
 
 
/**
 * Does Polygon have Z values?
 * @type {boolean|undefined}
 */
EsriJSONPolygon.prototype.hasZ;
 
 
/**
 * @type {!Array.<!Array.<!Array.<number>>>}
 */
EsriJSONPolygon.prototype.rings;
 
 
/**
 * @typedef {(EsriJSONPoint|EsriJSONMultipoint|EsriJSONPolyline|
           EsriJSONPolygon)}
 */
var EsriJSONGeometry;
 
 
/**
 * @constructor
 * @extends {EsriJSONObject}
 */
var EsriJSONFeature = function() {};
 
 
/**
 * @type {EsriJSONGeometry}
 */
EsriJSONFeature.prototype.geometry;
 
 
/**
 * @type {Object.<string, *>}
 */
EsriJSONFeature.prototype.attributes;
 
 
 
/**
 * @constructor
 * @extends {EsriJSONObject}
 */
var EsriJSONFeatureCollection = function() {};
 
 
/**
 * @type {!Array.<EsriJSONFeature>}
 */
EsriJSONFeatureCollection.prototype.features;
 
 
/**
 * The name of the attribute that contains ids.
 * @type {string}
 */
EsriJSONFeatureCollection.prototype.objectIdFieldName;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/geojson.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/geojson.js

Statements: 100% (24 / 24)      Branches: 100% (0 / 0)      Functions: 0% (0 / 9)      Lines: 100% (24 / 24)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174                        1           1           1           1             1             1               1                     1               1             1           1               1             1               1           1               1           1           1           1               1           1             1           1         1    
 
/**
 * @fileoverview Externs for GeoJSON.
 * @see http://geojson.org/geojson-spec.html
 * @externs
 */
 
 
 
/**
 * @constructor
 */
var GeoJSONObject = function() {};
 
 
/**
 * @type {!Array.<number>|undefined}
 */
GeoJSONObject.prototype.bbox;
 
 
/**
 * @type {string}
 */
GeoJSONObject.prototype.type;
 
 
/**
 * @type {!GeoJSONCRS|undefined}
 */
GeoJSONObject.prototype.crs;
 
 
 
/**
 * @constructor
 */
var GeoJSONCRS = function() {};
 
 
/**
 * CRS type. One of `link` or `name`.
 * @type {string}
 */
GeoJSONCRS.prototype.type;
 
 
/**
 * TODO: remove GeoJSONCRSCode when http://jira.codehaus.org/browse/GEOS-5996
 * is fixed and widely deployed.
 * @type {!GeoJSONCRSCode|!GeoJSONCRSName|!GeoJSONLink}
 */
GeoJSONCRS.prototype.properties;
 
 
 
/**
 * `GeoJSONCRSCode` is not part of the GeoJSON specification, but is generated
 * by GeoServer.
 * TODO: remove GeoJSONCRSCode when http://jira.codehaus.org/browse/GEOS-5996
 * is fixed and widely deployed.
 * @constructor
 */
var GeoJSONCRSCode = function() {};
 
 
/**
 * TODO: remove this when http://jira.codehaus.org/browse/GEOS-5996 is fixed
 * and widely deployed.
 * @type {string}
 */
GeoJSONCRSCode.prototype.code;
 
 
 
/**
 * @constructor
 */
var GeoJSONCRSName = function() {};
 
 
/**
 * @type {string}
 */
GeoJSONCRSName.prototype.name;
 
 
 
/**
 * @constructor
 * @extends {GeoJSONObject}
 */
var GeoJSONGeometry = function() {};
 
 
/**
 * @type {!Array.<number>|!Array.<!Array.<number>>|
 *        !Array.<!Array.<!Array.<number>>>}
 */
GeoJSONGeometry.prototype.coordinates;
 
 
 
/**
 * @constructor
 * @extends {GeoJSONObject}
 */
var GeoJSONGeometryCollection = function() {};
 
 
/**
 * @type {!Array.<GeoJSONGeometry>}
 */
GeoJSONGeometryCollection.prototype.geometries;
 
 
 
/**
 * @constructor
 * @extends {GeoJSONObject}
 */
var GeoJSONFeature = function() {};
 
 
/**
 * @type {GeoJSONGeometry|GeoJSONGeometryCollection}
 */
GeoJSONFeature.prototype.geometry;
 
 
/**
 * @type {number|string|undefined}
 */
GeoJSONFeature.prototype.id;
 
 
/**
 * @type {Object.<string, *>}
 */
GeoJSONFeature.prototype.properties;
 
 
 
/**
 * @constructor
 * @extends {GeoJSONObject}
 */
var GeoJSONFeatureCollection = function() {};
 
 
/**
 * @type {!Array.<GeoJSONFeature>}
 */
GeoJSONFeatureCollection.prototype.features;
 
 
 
/**
 * @constructor
 */
var GeoJSONLink = function() {};
 
 
/**
 * @type {string}
 */
GeoJSONLink.prototype.href;
 
/**
 * @type {string}
 */
GeoJSONLink.prototype.type;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/jquery-1.9.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/jquery-1.9.js

Statements: 5.42% (16 / 295)      Branches: 100% (0 / 0)      Functions: 0% (0 / 231)      Lines: 5.42% (16 / 295)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830                                                                          2     2                                                                           2                   1         2               2             2           2             2             2           2           2           2           2     2     2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              
/*
 * Copyright 2011 The Closure Compiler Authors.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
 
/**
 * @fileoverview Externs for jQuery 1.9 - 1.11 & 2.0 - 2.1
 *
 * The jQuery API is identical for the 1.9.x+ and 2.0+ branches. In addition,
 * the API has not changed in releases since that date. These externs are valid
 * for all jQuery releases since 1.9 and 2.0.
 *
 * Note that some functions use different return types depending on the number
 * of parameters passed in. In these cases, you may need to annotate the type
 * of the result in your code, so the JSCompiler understands which type you're
 * expecting. For example:
 *    <code>var elt = /** @type {Element} * / (foo.get(0));</code>
 *
 * @see http://api.jquery.com/
 * @externs
 */
 
/**
 * @typedef {(Window|Document|Element|Array<Element>|string|jQuery|
 *     NodeList)}
 */
var jQuerySelector;
 
/** @typedef {function(...)|Array<function(...)>} */
var jQueryCallback;
 
/** @typedef {
              {
               accepts: (Object<string, string>|undefined),
               async: (?boolean|undefined),
               beforeSend: (function(jQuery.jqXHR, (jQueryAjaxSettings|Object<string, *>))|undefined),
               cache: (?boolean|undefined),
               complete: (function(jQuery.jqXHR, string)|undefined),
               contents: (Object<string, RegExp>|undefined),
               contentType: (?string|undefined),
               context: (Object<?, ?>|jQueryAjaxSettings|undefined),
               converters: (Object<string, Function>|undefined),
               crossDomain: (?boolean|undefined),
               data: (Object<?, ?>|?string|Array<?>|undefined),
               dataFilter: (function(string, string):?|undefined),
               dataType: (?string|undefined),
               error: (function(jQuery.jqXHR, string, string)|undefined),
               global: (?boolean|undefined),
               headers: (Object<?, ?>|undefined),
               ifModified: (?boolean|undefined),
               isLocal: (?boolean|undefined),
               jsonp: (?string|undefined),
               jsonpCallback: (?string|function()|undefined),
               mimeType: (?string|undefined),
               password: (?string|undefined),
               processData: (?boolean|undefined),
               scriptCharset: (?string|undefined),
               statusCode: (Object<number, function()>|undefined),
               success: (function(?, string, jQuery.jqXHR)|undefined),
               timeout: (?number|undefined),
               traditional: (?boolean|undefined),
               type: (?string|undefined),
               url: (?string|undefined),
               username: (?string|undefined),
               xhr: (function():(ActiveXObject|XMLHttpRequest)|undefined),
               xhrFields: (Object<?, ?>|undefined)
              }} */
var jQueryAjaxSettings;
 
/**
 * @constructor
 * @param {(jQuerySelector|Element|Object|Array<Element>|jQuery|string|
 *     function())=} arg1
 * @param {(Element|jQuery|Document|
 *     Object<string, (string|function(!jQuery.Event))>)=} arg2
 * @return {!jQuery}
 */
function jQuery(arg1, arg2) {}
 
/**
 * @const
 */
var $ = jQuery;
 
/**
 * @param {(jQuerySelector|Array<Element>|string|jQuery)} arg1
 * @param {Element=} context
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.add = function(arg1, context) {};
 
/**
 * @param {(jQuerySelector|Array<Element>|string|jQuery)=} arg1
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.addBack = function(arg1) {};
 
/**
 * @param {(string|function(number,String))} arg1
 * @return {!jQuery}
 */
jQuery.prototype.addClass = function(arg1) {};
 
/**
 * @param {(string|Element|jQuery|function(number))} arg1
 * @param {(string|Element|Array<Element>|jQuery)=} content
 * @return {!jQuery}
 */
jQuery.prototype.after = function(arg1, content) {};
 
/**
 * @param {(string|jQueryAjaxSettings|Object<string,*>)} arg1
 * @param {(jQueryAjaxSettings|Object<string, *>)=} settings
 * @return {!jQuery.jqXHR}
 */
jQuery.ajax = function(arg1, settings) {};
 
/**
 * @param {function(!jQuery.Event,XMLHttpRequest,(jQueryAjaxSettings|Object<string, *>))} handler
 * @return {!jQuery}
 */
jQuery.prototype.ajaxComplete = function(handler) {};
 
/**
 * @param {function(!jQuery.Event,jQuery.jqXHR,(jQueryAjaxSettings|Object<string, *>),*)} handler
 * @return {!jQuery}
 */
jQuery.prototype.ajaxError = function(handler) {};
 
/**
 * @param {(string|function((jQueryAjaxSettings|Object<string, *>),(jQueryAjaxSettings|Object<string, *>),jQuery.jqXHR))} dataTypes
 * @param {function((jQueryAjaxSettings|Object<string, *>),(jQueryAjaxSettings|Object<string, *>),jQuery.jqXHR)=} handler
 */
jQuery.ajaxPrefilter = function(dataTypes, handler) {};
 
/**
 * @param {function(!jQuery.Event,jQuery.jqXHR,(jQueryAjaxSettings|Object<string, *>))} handler
 * @return {!jQuery}
 */
jQuery.prototype.ajaxSend = function(handler) {};
 
/** @const {jQueryAjaxSettings|Object<string, *>} */
jQuery.ajaxSettings;
 
/** @type {Object<string, boolean>} */
jQuery.ajaxSettings.flatOptions = {};
 
/** @type {boolean} */
jQuery.ajaxSettings.processData;
 
/** @type {Object<string, string>} */
jQuery.ajaxSettings.responseFields = {};
 
/** @param {jQueryAjaxSettings|Object<string, *>} options */
jQuery.ajaxSetup = function(options) {};
 
/**
 * @param {function()} handler
 * @return {!jQuery}
 */
jQuery.prototype.ajaxStart = function(handler) {};
 
/**
 * @param {function()} handler
 * @return {!jQuery}
 */
jQuery.prototype.ajaxStop = function(handler) {};
 
/**
 * @param {function(!jQuery.Event,XMLHttpRequest,(jQueryAjaxSettings|Object<string, *>), ?)} handler
 * @return {!jQuery}
 */
jQuery.prototype.ajaxSuccess = function(handler) {};
 
/**
 * @deprecated Please use .addBack(selector) instead.
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.andSelf = function() {};
 
/**
 * @param {Object<string,*>} properties
 * @param {(string|number|function()|Object<string,*>)=} arg2
 * @param {(string|function())=} easing
 * @param {function()=} complete
 * @return {!jQuery}
 */
jQuery.prototype.animate = function(properties, arg2, easing, complete) {};
 
/**
 * @param {(string|Element|Array<Element>|jQuery|function(number,string))} arg1
 * @param {...(string|Element|Array<Element>|jQuery)} content
 * @return {!jQuery}
 */
jQuery.prototype.append = function(arg1, content) {};
 
/**
 * @param {(jQuerySelector|Element|jQuery)} target
 * @return {!jQuery}
 */
jQuery.prototype.appendTo = function(target) {};
 
/**
 * @param {(string|Object<string,*>)} arg1
 * @param {(string|number|boolean|function(number,string))=} arg2
 * @return {(string|!jQuery)}
 */
jQuery.prototype.attr = function(arg1, arg2) {};
 
/**
 * @param {(string|Element|jQuery|function())} arg1
 * @param {(string|Element|Array<Element>|jQuery)=} content
 * @return {!jQuery}
 */
jQuery.prototype.before = function(arg1, content) {};
 
/**
 * @param {(string|Object<string, function(!jQuery.Event)>)} arg1
 * @param {(Object<string, *>|function(!jQuery.Event)|boolean)=} eventData
 * @param {(function(!jQuery.Event)|boolean)=} arg3
 * @return {!jQuery}
 */
jQuery.prototype.bind = function(arg1, eventData, arg3) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.blur = function(arg1, handler) {};
 
/**
 * @constructor
 * @private
 */
jQuery.callbacks = function () {};
 
/**
 * @param {string=} flags
 * @return {!jQuery.callbacks}
 */
jQuery.Callbacks = function (flags) {};
 
/** @param {function()} callbacks */
jQuery.callbacks.prototype.add = function(callbacks) {};
 
/** @return {undefined} */
jQuery.callbacks.prototype.disable = function() {};
 
/** @return {undefined} */
jQuery.callbacks.prototype.empty = function() {};
 
/** @param {...*} var_args */
jQuery.callbacks.prototype.fire = function(var_args) {};
 
/** @return {boolean} */
jQuery.callbacks.prototype.fired = function() {};
 
/** @param {...*} var_args */
jQuery.callbacks.prototype.fireWith = function(var_args) {};
 
/**
 * @param {function()} callback
 * @return {boolean}
 * @nosideeffects
 */
jQuery.callbacks.prototype.has = function(callback) {};
 
/** @return {undefined} */
jQuery.callbacks.prototype.lock = function() {};
 
/** @return {boolean} */
jQuery.callbacks.prototype.locked = function() {};
 
/** @param {function()} callbacks */
jQuery.callbacks.prototype.remove = function(callbacks) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.change = function(arg1, handler) {};
 
/**
 * @param {jQuerySelector=} selector
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.children = function(selector) {};
 
/**
 * @param {string=} queueName
 * @return {!jQuery}
 */
jQuery.prototype.clearQueue = function(queueName) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.click = function(arg1, handler) {};
 
/**
 * @param {boolean=} withDataAndEvents
 * @param {boolean=} deepWithDataAndEvents
 * @return {!jQuery}
 * @suppress {checkTypes} see https://code.google.com/p/closure-compiler/issues/detail?id=583
 */
jQuery.prototype.clone = function(withDataAndEvents, deepWithDataAndEvents) {};
 
/**
 * @param {(jQuerySelector|jQuery|Element|string)} arg1
 * @param {Element=} context
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.closest = function(arg1, context) {};
 
/**
 * @param {Element} container
 * @param {Element} contained
 * @return {boolean}
 */
jQuery.contains = function(container, contained) {};
 
/**
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.contents = function() {};
 
/** @type {Element|Document} */
jQuery.prototype.context;
 
/**
 * @param {(string|Object<string,*>)} arg1
 * @param {(string|number|function(number,*))=} arg2
 * @return {(string|!jQuery)}
 */
jQuery.prototype.css = function(arg1, arg2) {};
 
/** @type {Object<string, *>} */
jQuery.cssHooks;
 
/**
 * @param {Element} elem
 * @param {string=} key
 * @param {*=} value
 * @return {*}
 */
jQuery.data = function(elem, key, value) {};
 
/**
 * @param {(string|Object<string, *>)=} arg1
 * @param {*=} value
 * @return {*}
 */
jQuery.prototype.data = function(arg1, value) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.dblclick = function(arg1, handler) {};
 
/**
 * @constructor
 * @implements {jQuery.Promise}
 * @param {function()=} opt_fn
 * @see http://api.jquery.com/category/deferred-object/
 */
jQuery.deferred = function(opt_fn) {};
 
/**
 * @constructor
 * @extends {jQuery.deferred}
 * @param {function()=} opt_fn
 * @return {!jQuery.Deferred}
 */
jQuery.Deferred = function(opt_fn) {};
 
/**
 * @override
 * @param {jQueryCallback} alwaysCallbacks
 * @param {jQueryCallback=} alwaysCallbacks2
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.always
    = function(alwaysCallbacks, alwaysCallbacks2) {};
 
/**
 * @override
 * @param {jQueryCallback} doneCallbacks
 * @param {jQueryCallback=} doneCallbacks2
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.done = function(doneCallbacks, doneCallbacks2) {};
 
/**
 * @override
 * @param {jQueryCallback} failCallbacks
 * @param {jQueryCallback=} failCallbacks2
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.fail = function(failCallbacks, failCallbacks2) {};
 
/**
 * @param {...*} var_args
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.notify = function(var_args) {};
 
/**
 * @param {Object} context
 * @param {...*} var_args
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.notifyWith = function(context, var_args) {};
 
/**
 * @deprecated Please use deferred.then() instead.
 * @override
 * @param {function()=} doneFilter
 * @param {function()=} failFilter
 * @param {function()=} progressFilter
 * @return {!jQuery.Promise}
 */
jQuery.deferred.prototype.pipe =
    function(doneFilter, failFilter, progressFilter) {};
 
/**
 * @param {jQueryCallback} progressCallbacks
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.progress = function(progressCallbacks) {};
 
/**
 * @param {Object=} target
 * @return {!jQuery.Promise}
 */
jQuery.deferred.prototype.promise = function(target) {};
 
/**
 * @param {...*} var_args
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.reject = function(var_args) {};
 
/**
 * @param {Object} context
 * @param {Array<*>=} args
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.rejectWith = function(context, args) {};
 
/**
 * @param {...*} var_args
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.resolve = function(var_args) {};
 
/**
 * @param {Object} context
 * @param {Array<*>=} args
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.resolveWith = function(context, args) {};
 
/** @return {string} */
jQuery.deferred.prototype.state = function() {};
 
/**
 * @override
 * @param {jQueryCallback} doneCallbacks
 * @param {jQueryCallback=} failCallbacks
 * @param {jQueryCallback=} progressCallbacks
 * @return {!jQuery.deferred}
 */
jQuery.deferred.prototype.then
    = function(doneCallbacks, failCallbacks, progressCallbacks) {};
 
/**
 * @param {number} duration
 * @param {string=} queueName
 * @return {!jQuery}
 */
jQuery.prototype.delay = function(duration, queueName) {};
 
/**
 * @param {string} selector
 * @param {(string|Object<string,*>)} arg2
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg3
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.delegate = function(selector, arg2, arg3, handler) {};
 
/**
 * @param {Element} elem
 * @param {string=} queueName
 */
jQuery.dequeue = function(elem, queueName) {};
 
/**
 * @param {string=} queueName
 * @return {!jQuery}
 */
jQuery.prototype.dequeue = function(queueName) {};
 
/**
 * @param {jQuerySelector=} selector
 * @return {!jQuery}
 */
jQuery.prototype.detach = function(selector) {};
 
/**
 * @param {Object} collection
 * @param {function((number|string),?)} callback
 * @return {Object}
 */
jQuery.each = function(collection, callback) {};
 
/**
 * @param {function(number,Element)} fnc
 * @return {!jQuery}
 */
jQuery.prototype.each = function(fnc) {};
 
 
/** @return {!jQuery} */
jQuery.prototype.empty = function() {};
 
/**
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.end = function() {};
 
/**
 * @param {number} arg1
 * @return {!jQuery}
 */
jQuery.prototype.eq = function(arg1) {};
 
/** @param {string} message */
jQuery.error = function(message) {};
 
/**
 * @deprecated Please use .on( "error", handler ) instead.
 * @param {(function(!jQuery.Event)|Object<string, *>)} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.error = function(arg1, handler) {};
 
/** @const */
jQuery.event = {};
 
/** @type {Array<string>} */
jQuery.event.props;
 
/** @type {Object<string, Object>} */
jQuery.event.special;
 
/**
 * @constructor
 * @param {string} eventType
 * @param {Object=} properties
 * @return {!jQuery.Event}
 */
jQuery.Event = function(eventType, properties) {};
 
/** @type {boolean} */
jQuery.Event.prototype.altKey;
 
/** @type {boolean} */
jQuery.Event.prototype.bubbles;
 
/** @type {number} */
jQuery.Event.prototype.button;
 
/** @type {boolean} */
jQuery.Event.prototype.cancelable;
 
/** @type {string} */
jQuery.Event.prototype.charChode;
 
/** @type {number} */
jQuery.Event.prototype.clientX;
 
/** @type {number} */
jQuery.Event.prototype.clientY;
 
/** @type {boolean} */
jQuery.Event.prototype.ctrlKey;
 
/** @type {Element} */
jQuery.Event.prototype.currentTarget;
 
/** @type {Object<string, *>} */
jQuery.Event.prototype.data;
 
/** @type {Element} */
jQuery.Event.prototype.delegateTarget;
 
/** @type {number} */
jQuery.Event.prototype.detail;
 
/** @type {number} */
jQuery.Event.prototype.eventPhase;
 
/**
 * @return {boolean}
 * @nosideeffects
 */
jQuery.Event.prototype.isDefaultPrevented = function() {};
 
/**
 * @return {boolean}
 * @nosideeffects
 */
jQuery.Event.prototype.isImmediatePropagationStopped = function() {};
 
/**
 * @return {boolean}
 * @nosideeffects
 */
jQuery.Event.prototype.isPropagationStopped = function() {};
 
/** @type {boolean} */
jQuery.Event.prototype.metaKey;
 
/** @type {string} */
jQuery.Event.prototype.namespace;
 
/** @type {number} */
jQuery.Event.prototype.offsetX;
 
/** @type {number} */
jQuery.Event.prototype.offsetY;
 
/** @type {Event} */
jQuery.Event.prototype.originalEvent;
 
/** @type {Element} */
jQuery.Event.prototype.originalTarget;
 
/** @type {number} */
jQuery.Event.prototype.pageX;
 
/** @type {number} */
jQuery.Event.prototype.pageY;
 
/** @return {undefined} */
jQuery.Event.prototype.preventDefault = function() {};
 
/** @type {Object<string, *>} */
jQuery.Event.prototype.props;
 
/** @type {Element} */
jQuery.Event.prototype.relatedTarget;
 
/** @type {*} */
jQuery.Event.prototype.result;
 
/** @type {number} */
jQuery.Event.prototype.screenX;
 
/** @type {number} */
jQuery.Event.prototype.screenY;
 
/** @type {boolean} */
jQuery.Event.prototype.shiftKey;
 
/** @return {undefined} */
jQuery.Event.prototype.stopImmediatePropagation = function() {};
 
/** @return {undefined} */
jQuery.Event.prototype.stopPropagation = function() {};
 
/** @type {Element} */
jQuery.Event.prototype.target;
 
/** @type {number} */
jQuery.Event.prototype.timeStamp;
 
/** @type {string} */
jQuery.Event.prototype.type;
 
/** @type {Window} */
jQuery.Event.prototype.view;
 
/** @type {number} */
jQuery.Event.prototype.which;
 
/**
 * @param {(Object|boolean)} arg1
 * @param {...*} var_args
 * @return {Object}
 */
jQuery.extend = function(arg1, var_args) {};
 
/**
 * @param {(Object|boolean)} arg1
 * @param {...*} var_args
 * @return {Object}
 */
jQuery.prototype.extend = function(arg1, var_args) {};
 
/**
 * @param {(string|number|function())=} duration
 * @param {(function()|string)=} arg2
 * @param {function()=} callback
 * @return {!jQuery}
 */
jQuery.prototype.fadeIn = function(duration, arg2, callback) {};
 
/**
 * @param {(string|number|function())=} duration
 * @param {(function()|string)=} arg2
 * @param {function()=} callback
 * @return {!jQuery}
 */
jQuery.prototype.fadeOut = function(duration, arg2, callback) {};
 
/**
 * @param {(string|number)} duration
 * @param {number} opacity
 * @param {(function()|string)=} arg3
 * @param {function()=} callback
 * @return {!jQuery}
 */
jQuery.prototype.fadeTo = function(duration, opacity, arg3, callback) {};
 
/**
 * @param {(string|number|function())=} duration
 * @param {(string|function())=} easing
 * @param {function()=} callback
 * @return {!jQuery}
 */
jQuery.prototype.fadeToggle = function(duration, easing, callback) {};
 
/**
 * @param {(jQuerySelector|function(number,Element)|Element|jQuery)} arg1
 * @return {!jQuery}
 * @see http://api.jquery.com/filter/
 */
jQuery.prototype.filter = function(arg1) {};
 
/**
 * @param {(jQuerySelector|jQuery|Element)} arg1
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.find = function(arg1) {};
 
/** @return {!jQuery} */
jQuery.prototype.first = function() {};
 
/** @see http://docs.jquery.com/Plugins/Authoring */
jQuery.fn = jQuery.prototype;
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.focus = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.focusin = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.focusout = function(arg1, handler) {};
 
/** @const */
jQuery.fx = {};
 
/** @type {number} */
jQuery.fx.interval;
 
/** @type {boolean} */
jQuery.fx.off;
 
/**
 * @param {string} url
 * @param {(Object<string,*>|string|
 *     function(string,string,jQuery.jqXHR))=} data
 * @param {(function(string,string,jQuery.jqXHR)|string)=} success
 * @param {string=} dataType
 * @return {!jQuery.jqXHR}
 */
jQuery.get = function(url, data, success, dataType) {};
 
/**
 * @param {number=} index
 * @return {(Element|Array<Element>)}
 * @nosideeffects
 */
jQuery.prototype.get = function(index) {};
 
/**
 * @param {string} url
 * @param {(Object<string,*>|
 *     function(Object<string,*>,string,jQuery.jqXHR))=} data
 * @param {function(Object<string,*>,string,jQuery.jqXHR)=} success
 * @return {!jQuery.jqXHR}
 * @see http://api.jquery.com/jquery.getjson/#jQuery-getJSON-url-data-success
 */
jQuery.getJSON = function(url, data, success) {};
 
/**
 * @param {string} url
 * @param {function(Node,string,jQuery.jqXHR)=} success
 * @return {!jQuery.jqXHR}
 */
jQuery.getScript = function(url, success) {};
 
/** @param {string} code */
jQuery.globalEval = function(code) {};
 
/**
 * @template T
 * @param {!Array<T>} arr
 * @param {function(*,number)} fnc
 * @param {boolean=} invert
 * @return {!Array<T>}
 */
jQuery.grep = function(arr, fnc, invert) {};
 
/**
 * @param {(string|Element)} arg1
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.has = function(arg1) {};
 
/**
 * @param {string} className
 * @return {boolean}
 * @nosideeffects
 */
jQuery.prototype.hasClass = function(className) {};
 
/**
 * @param {!Element} elem
 * @return {boolean}
 * @nosideeffects
 */
jQuery.hasData = function(elem) {};
 
/**
 * @param {(string|number|function(number,number))=} arg1
 * @return {(number|!jQuery)}
 */
jQuery.prototype.height = function(arg1) {};
 
/**
 * @param {(string|number|function())=} duration
 * @param {(function()|string)=} arg2
 * @param {function()=} callback
 * @return {!jQuery}
 */
jQuery.prototype.hide = function(duration, arg2, callback) {};
 
/** @param {boolean} hold */
jQuery.holdReady = function(hold) {};
 
/**
 * @param {function(!jQuery.Event)} arg1
 * @param {function(!jQuery.Event)=} handlerOut
 * @return {!jQuery}
 */
jQuery.prototype.hover = function(arg1, handlerOut) {};
 
/**
 * @param {(string|function(number,string))=} arg1
 * @return {(string|!jQuery)}
 */
jQuery.prototype.html = function(arg1) {};
 
/**
 * @param {*} value
 * @param {Array<*>} arr
 * @param {number=} fromIndex
 * @return {number}
 * @nosideeffects
 */
jQuery.inArray = function(value, arr, fromIndex) {};
 
/**
 * @param {(jQuerySelector|Element|jQuery)=} arg1
 * @return {number}
 */
jQuery.prototype.index = function(arg1) {};
 
/**
 * @return {number}
 * @nosideeffects
 */
jQuery.prototype.innerHeight = function() {};
 
/**
 * @return {number}
 * @nosideeffects
 */
jQuery.prototype.innerWidth = function() {};
 
/**
 * @param {(jQuerySelector|Element|jQuery)} target
 * @return {!jQuery}
 */
jQuery.prototype.insertAfter = function(target) {};
 
/**
 * @param {(jQuerySelector|Element|jQuery)} target
 * @return {!jQuery}
 */
jQuery.prototype.insertBefore = function(target) {};
 
/**
 * @param {(jQuerySelector|function(number)|jQuery|Element)} arg1
 * @return {boolean}
 */
jQuery.prototype.is = function(arg1) {};
 
/**
 * @param {*} obj
 * @return {boolean}
 * @nosideeffects
 */
jQuery.isArray = function(obj) {};
 
/**
 * @param {Object} obj
 * @return {boolean}
 * @nosideeffects
 */
jQuery.isEmptyObject = function(obj) {};
 
/**
 * @param {*} obj
 * @return {boolean}
 * @nosideeffects
 */
jQuery.isFunction = function(obj) {};
 
/**
 * @param {*} value
 * @return {boolean}
 * @nosideeffects
 */
jQuery.isNumeric = function(value) {};
 
/**
 * @param {*} obj
 * @return {boolean}
 * @nosideeffects
 */
jQuery.isPlainObject = function(obj) {};
 
/**
 * @param {*} obj
 * @return {boolean}
 * @nosideeffects
 */
jQuery.isWindow = function(obj) {};
 
/**
 * @param {Element} node
 * @return {boolean}
 * @nosideeffects
 */
jQuery.isXMLDoc = function(node) {};
 
/** @type {string} */
jQuery.prototype.jquery;
 
/**
 * @constructor
 * @extends {XMLHttpRequest}
 * @implements {jQuery.Promise}
 * @private
 * @see http://api.jquery.com/jQuery.ajax/#jqXHR
 */
jQuery.jqXHR = function () {};
 
/**
 * @override
 * @param {jQueryCallback} alwaysCallbacks
 * @param {jQueryCallback=} alwaysCallbacks2
 * @return {!jQuery.jqXHR}
 */
jQuery.jqXHR.prototype.always =
    function(alwaysCallbacks, alwaysCallbacks2) {};
 
/**
 * @deprecated
 * @param {function()} callback
 * @return {!jQuery.jqXHR}
*/
jQuery.jqXHR.prototype.complete = function (callback) {};
 
/**
 * @override
 * @param {jQueryCallback} doneCallbacks
 * @return {!jQuery.jqXHR}
 */
jQuery.jqXHR.prototype.done = function(doneCallbacks) {};
 
/**
 * @deprecated
 * @param {function()} callback
 * @return {!jQuery.jqXHR}
*/
jQuery.jqXHR.prototype.error = function (callback) {};
 
/**
 * @override
 * @param {jQueryCallback} failCallbacks
 * @return {!jQuery.jqXHR}
 */
jQuery.jqXHR.prototype.fail = function(failCallbacks) {};
 
/**
 * @deprecated
 * @override
 */
jQuery.jqXHR.prototype.onreadystatechange = function (callback) {};
 
/**
 * @override
 * @param {function()=} doneFilter
 * @param {function()=} failFilter
 * @param {function()=} progressFilter
 * @return {!jQuery.jqXHR}
 */
jQuery.jqXHR.prototype.pipe =
    function(doneFilter, failFilter, progressFilter) {};
 
/**
 * @deprecated
 * @param {function()} callback
 * @return {!jQuery.jqXHR}
*/
jQuery.jqXHR.prototype.success = function (callback) {};
 
/**
 * @override
 * @param {jQueryCallback} doneCallbacks
 * @param {jQueryCallback=} failCallbacks
 * @param {jQueryCallback=} progressCallbacks
 * @return {!jQuery.jqXHR}
 */
jQuery.jqXHR.prototype.then =
    function(doneCallbacks, failCallbacks, progressCallbacks) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.keydown = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.keypress = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.keyup = function(arg1, handler) {};
 
/** @return {!jQuery} */
jQuery.prototype.last = function() {};
 
/** @type {number} */
jQuery.prototype.length;
 
/**
 * @deprecated Please avoid the document loading Event invocation of
 *     .load() and use .on( "load", handler ) instead. (The AJAX
 *     module invocation signature is OK.)
 * @param {(function(!jQuery.Event)|Object<string, *>|string)} arg1
 * @param {(function(!jQuery.Event)|Object<string,*>|string)=} arg2
 * @param {function(string,string,XMLHttpRequest)=} complete
 * @return {!jQuery}
 */
jQuery.prototype.load = function(arg1, arg2, complete) {};
 
/**
 * @param {*} obj
 * @return {Array<*>}
 */
jQuery.makeArray = function(obj) {};
 
/**
 * @param {(Array<*>|Object<string, *>)} arg1
 * @param {(function(*,number)|function(*,(string|number)))} callback
 * @return {Array<*>}
 */
jQuery.map = function(arg1, callback) {};
 
/**
 * @param {function(number,Element)} callback
 * @return {!jQuery}
 */
jQuery.prototype.map = function(callback) {};
 
/**
 * @param {Array<*>} first
 * @param {Array<*>} second
 * @return {Array<*>}
 */
jQuery.merge = function(first, second) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.mousedown = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.mouseenter = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.mouseleave = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.mousemove = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.mouseout = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.mouseover = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.mouseup = function(arg1, handler) {};
 
/**
 * @param {jQuerySelector=} selector
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.next = function(selector) {};
 
/**
 * @param {string=} selector
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.nextAll = function(selector) {};
 
/**
 * @param {(jQuerySelector|Element)=} arg1
 * @param {jQuerySelector=} filter
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.nextUntil = function(arg1, filter) {};
 
/**
 * @param {boolean=} removeAll
 * @return {Object}
 */
jQuery.noConflict = function(removeAll) {};
 
/**
 * @return {function()}
 * @nosideeffects
 */
jQuery.noop = function() {};
 
/**
 * @param {(jQuerySelector|Array<Element>|function(number)|jQuery)} arg1
 * @return {!jQuery}
 */
jQuery.prototype.not = function(arg1) {};
 
/**
 * @return {number}
 * @nosideeffects
 */
jQuery.now = function() {};
 
/**
 * @param {(string|Object<string,*>)=} arg1
 * @param {(string|function(!jQuery.Event))=} selector
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.off = function(arg1, selector, handler) {};
 
/**
 * @param {({left:number,top:number}|
 *     function(number,{top:number,left:number}))=} arg1
 * @return {({left:number,top:number}|!jQuery)}
 */
jQuery.prototype.offset = function(arg1) {};
 
/**
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.offsetParent = function() {};
 
/**
 * @param {(string|Object<string,*>)} arg1
 * @param {*=} selector
 * @param {*=} data
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.on = function(arg1, selector, data, handler) {};
 
/**
 * @param {(string|Object<string,*>)} arg1
 * @param {*=} arg2
 * @param {*=} arg3
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.one = function(arg1, arg2, arg3, handler) {};
 
/**
 * @param {boolean=} includeMargin
 * @return {number}
 * @nosideeffects
 */
jQuery.prototype.outerHeight = function(includeMargin) {};
 
/**
 * @param {boolean=} includeMargin
 * @return {number}
 * @nosideeffects
 */
jQuery.prototype.outerWidth = function(includeMargin) {};
 
/**
 * @param {(Object<string, *>|Array<Object<string, *>>)} obj
 * @param {boolean=} traditional
 * @return {string}
 */
jQuery.param = function(obj, traditional) {};
 
/**
 * @param {jQuerySelector=} selector
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.parent = function(selector) {};
 
/**
 * @param {jQuerySelector=} selector
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.parents = function(selector) {};
 
/**
 * @param {(jQuerySelector|Element)=} arg1
 * @param {jQuerySelector=} filter
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.parentsUntil = function(arg1, filter) {};
 
/**
 * @param {string} data
 * @param {(Element|boolean)=} context
 * @param {boolean=} keepScripts
 * @return {Array<Element>}
 */
jQuery.parseHTML = function(data, context, keepScripts) {};
 
/**
 * @param {string} json
 * @return {string|number|Object<string, *>|Array<?>|boolean}
 */
jQuery.parseJSON = function(json) {};
 
/**
 * @param {string} data
 * @return {Document}
 */
jQuery.parseXML = function(data) {};
 
/**
 * @return {{left:number,top:number}}
 * @nosideeffects
 */
jQuery.prototype.position = function() {};
 
/**
 * @param {string} url
 * @param {(Object<string,*>|string|
 *     function(string,string,jQuery.jqXHR))=} data
 * @param {(function(string,string,jQuery.jqXHR)|string|null)=} success
 * @param {string=} dataType
 * @return {!jQuery.jqXHR}
 */
jQuery.post = function(url, data, success, dataType) {};
/**
 * @param {(string|Element|jQuery|function(number,string))} arg1
 * @param {(string|Element|jQuery)=} content
 * @return {!jQuery}
 */
jQuery.prototype.prepend = function(arg1, content) {};
 
/**
 * @param {(jQuerySelector|Element|jQuery)} target
 * @return {!jQuery}
 */
jQuery.prototype.prependTo = function(target) {};
 
/**
 * @param {jQuerySelector=} selector
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.prev = function(selector) {};
 
/**
 * @param {jQuerySelector=} selector
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.prevAll = function(selector) {};
 
/**
 * @param {(jQuerySelector|Element)=} arg1
 * @param {jQuerySelector=} filter
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.prevUntil = function(arg1, filter) {};
 
/**
 * @param {(string|Object)=} type
 * @param {Object=} target
 * @return {!jQuery.Promise}
 */
jQuery.prototype.promise = function(type, target) {};
 
/**
 * @interface
 * @private
 * @see http://api.jquery.com/Types/#Promise
 */
jQuery.Promise = function () {};
 
/**
 * @param {jQueryCallback} alwaysCallbacks
 * @param {jQueryCallback=} alwaysCallbacks2
 * @return {!jQuery.Promise}
 */
jQuery.Promise.prototype.always =
    function(alwaysCallbacks, alwaysCallbacks2) {};
 
/**
 * @param {jQueryCallback} doneCallbacks
 * @return {!jQuery.Promise}
 */
jQuery.Promise.prototype.done = function(doneCallbacks) {};
 
/**
 * @param {jQueryCallback} failCallbacks
 * @return {!jQuery.Promise}
 */
jQuery.Promise.prototype.fail = function(failCallbacks) {};
 
/**
 * @param {function()=} doneFilter
 * @param {function()=} failFilter
 * @param {function()=} progressFilter
 * @return {!jQuery.Promise}
 */
jQuery.Promise.prototype.pipe =
    function(doneFilter, failFilter, progressFilter) {};
 
/**
 * @param {jQueryCallback} doneCallbacks
 * @param {jQueryCallback=} failCallbacks
 * @param {jQueryCallback=} progressCallbacks
 * @return {!jQuery.Promise}
 */
jQuery.Promise.prototype.then =
    function(doneCallbacks, failCallbacks, progressCallbacks) {};
 
/**
 * @param {(string|Object<string,*>)} arg1
 * @param {(string|number|boolean|function(number,String))=} arg2
 * @return {(string|boolean|!jQuery)}
 */
jQuery.prototype.prop = function(arg1, arg2) {};
 
/**
 * @param {...*} var_args
 * @return {function()}
 */
jQuery.proxy = function(var_args) {};
 
/**
 * @param {Array<Element>} elements
 * @param {string=} name
 * @param {Array<*>=} args
 * @return {!jQuery}
 */
jQuery.prototype.pushStack = function(elements, name, args) {};
 
/**
 * @param {(string|Array<function()>|function(function()))=} queueName
 * @param {(Array<function()>|function(function()))=} arg2
 * @return {(Array<Element>|!jQuery)}
 */
jQuery.prototype.queue = function(queueName, arg2) {};
 
/**
 * @param {Element} elem
 * @param {string=} queueName
 * @param {(Array<function()>|function())=} arg3
 * @return {(Array<Element>|!jQuery)}
 */
jQuery.queue = function(elem, queueName, arg3) {};
 
/**
 * @param {function()} handler
 * @return {!jQuery}
 */
jQuery.prototype.ready = function(handler) {};
 
/**
 * @param {string=} selector
 * @return {!jQuery}
 */
jQuery.prototype.remove = function(selector) {};
 
/**
 * @param {string} attributeName
 * @return {!jQuery}
 */
jQuery.prototype.removeAttr = function(attributeName) {};
 
/**
 * @param {(string|function(number,string))=} arg1
 * @return {!jQuery}
 */
jQuery.prototype.removeClass = function(arg1) {};
 
/**
 * @param {(string|Array<string>)=} arg1
 * @return {!jQuery}
 */
jQuery.prototype.removeData = function(arg1) {};
 
/**
 * @param {Element} elem
 * @param {string=} name
 * @return {!jQuery}
 */
jQuery.removeData = function(elem, name) {};
 
/**
 * @param {string} propertyName
 * @return {!jQuery}
 */
jQuery.prototype.removeProp = function(propertyName) {};
 
/**
 * @param {jQuerySelector} target
 * @return {!jQuery}
 */
jQuery.prototype.replaceAll = function(target) {};
 
/**
 * @param {(string|Element|jQuery|function())} arg1
 * @return {!jQuery}
 */
jQuery.prototype.replaceWith = function(arg1) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.resize = function(arg1, handler) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.scroll = function(arg1, handler) {};
 
/**
 * @param {number=} value
 * @return {(number|!jQuery)}
 */
jQuery.prototype.scrollLeft = function(value) {};
 
/**
 * @param {number=} value
 * @return {(number|!jQuery)}
 */
jQuery.prototype.scrollTop = function(value) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.select = function(arg1, handler) {};
 
/**
 * @return {string}
 * @nosideeffects
 */
jQuery.prototype.serialize = function() {};
 
/**
 * @return {Array<Object<string, *>>}
 * @nosideeffects
 */
jQuery.prototype.serializeArray = function() {};
 
/**
 * @param {(string|number|function())=} duration
 * @param {(function()|string)=} arg2
 * @param {function()=} callback
 * @return {!jQuery}
 */
jQuery.prototype.show = function(duration, arg2, callback) {};
 
/**
 * @param {jQuerySelector=} selector
 * @return {!jQuery}
 * @nosideeffects
 */
jQuery.prototype.siblings = function(selector) {};
 
/**
 * @deprecated Please use the .length property instead.
 * @return {number}
 * @nosideeffects
 */
jQuery.prototype.size = function() {};
 
/**
 * @param {number} start
 * @param {number=} end
 * @return {!jQuery}
 */
jQuery.prototype.slice = function(start, end) {};
 
/**
 * @param {(Object<string,*>|string|number)=} optionsOrDuration
 * @param {(function()|string)=} completeOrEasing
 * @param {function()=} complete
 * @return {!jQuery}
 */
jQuery.prototype.slideDown =
    function(optionsOrDuration, completeOrEasing, complete) {};
 
/**
 * @param {(Object<string,*>|string|number)=} optionsOrDuration
 * @param {(function()|string)=} completeOrEasing
 * @param {function()=} complete
 * @return {!jQuery}
 */
jQuery.prototype.slideToggle =
    function(optionsOrDuration, completeOrEasing, complete) {};
 
/**
 * @param {(Object<string,*>|string|number)=} optionsOrDuration
 * @param {(function()|string)=} completeOrEasing
 * @param {function()=} complete
 * @return {!jQuery}
 */
jQuery.prototype.slideUp =
    function(optionsOrDuration, completeOrEasing, complete) {};
 
/**
 * @param {(boolean|string)=} arg1
 * @param {boolean=} arg2
 * @param {boolean=} jumpToEnd
 * @return {!jQuery}
 */
jQuery.prototype.stop = function(arg1, arg2, jumpToEnd) {};
 
/**
 * @param {(function(!jQuery.Event)|Object<string, *>)=} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.submit = function(arg1, handler) {};
 
/** @type {Object<string, *>}
 * @deprecated Please try to use feature detection instead.
 */
jQuery.support;
 
/**
 * @deprecated Please try to use feature detection instead.
 * @type {boolean}
 */
jQuery.support.boxModel;
 
/** @type {boolean} */
jQuery.support.changeBubbles;
 
/** @type {boolean} */
jQuery.support.cors;
 
/** @type {boolean} */
jQuery.support.cssFloat;
 
/** @type {boolean} */
jQuery.support.hrefNormalized;
 
/** @type {boolean} */
jQuery.support.htmlSerialize;
 
/** @type {boolean} */
jQuery.support.leadingWhitespace;
 
/** @type {boolean} */
jQuery.support.noCloneEvent;
 
/** @type {boolean} */
jQuery.support.opacity;
 
/** @type {boolean} */
jQuery.support.style;
 
/** @type {boolean} */
jQuery.support.submitBubbles;
 
/** @type {boolean} */
jQuery.support.tbody;
 
/**
 * @param {(string|number|boolean|function(number,string))=} arg1
 * @return {(string|!jQuery)}
 */
jQuery.prototype.text = function(arg1) {};
 
/**
 * @return {Array<Element>}
 * @nosideeffects
 */
jQuery.prototype.toArray = function() {};
 
/**
 * Refers to the method from the Effects category. There used to be a toggle
 * method on the Events category which was removed starting version 1.9.
 * @param {(number|string|Object<string,*>|boolean)=} arg1
 * @param {(function()|string)=} arg2
 * @param {function()=} arg3
 * @return {!jQuery}
 */
jQuery.prototype.toggle = function(arg1, arg2, arg3) {};
 
/**
 * @param {(string|boolean|function(number,string,boolean))=} arg1
 * @param {boolean=} flag
 * @return {!jQuery}
 */
jQuery.prototype.toggleClass = function(arg1, flag) {};
 
/**
 * @param {(string|jQuery.Event)} arg1
 * @param {...*} var_args
 * @return {!jQuery}
 */
jQuery.prototype.trigger = function(arg1, var_args) {};
 
/**
 * @param {string|jQuery.Event} eventType
 * @param {Array<*>=} extraParameters
 * @return {*}
 */
jQuery.prototype.triggerHandler = function(eventType, extraParameters) {};
 
/**
 * @param {string} str
 * @return {string}
 * @nosideeffects
 */
jQuery.trim = function(str) {};
 
/**
 * @param {*} obj
 * @return {string}
 * @nosideeffects
 */
jQuery.type = function(obj) {};
 
/**
 * @param {(string|function(!jQuery.Event)|jQuery.Event)=} arg1
 * @param {(function(!jQuery.Event)|boolean)=} arg2
 * @return {!jQuery}
 */
jQuery.prototype.unbind = function(arg1, arg2) {};
 
/**
 * @param {string=} arg1
 * @param {(string|Object<string,*>)=} arg2
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.undelegate = function(arg1, arg2, handler) {};
 
/**
 * @param {Array<Element>} arr
 * @return {Array<Element>}
 */
jQuery.unique = function(arr) {};
 
/**
 * @deprecated Please use .on( "unload", handler ) instead.
 * @param {(function(!jQuery.Event)|Object<string, *>)} arg1
 * @param {function(!jQuery.Event)=} handler
 * @return {!jQuery}
 */
jQuery.prototype.unload = function(arg1, handler) {};
 
/** @return {!jQuery} */
jQuery.prototype.unwrap = function() {};
 
/**
 * @param {(string|Array<string>|function(number,*))=} arg1
 * @return {(string|number|Array<string>|!jQuery)}
 */
jQuery.prototype.val = function(arg1) {};
 
/**
 * Note: The official documentation (https://api.jquery.com/jQuery.when/) says
 * jQuery.when accepts deferreds, but it actually accepts any type, e.g.:
 *
 * jQuery.when(jQuery.ready, jQuery.ajax(''), jQuery('#my-element'), 1)
 *
 * If an argument is not an "observable" (a promise-like object) it is wrapped
 * into a promise.
 * @param {*} deferred
 * @param {...*} deferreds
 * @return {!jQuery.Promise}
 */
jQuery.when = function(deferred, deferreds) {};
 
/**
 * @param {(string|number|function(number,number))=} arg1
 * @return {(number|!jQuery)}
 */
jQuery.prototype.width = function(arg1) {};
 
/**
 * @param {(string|jQuerySelector|Element|jQuery|function(number))} arg1
 * @return {!jQuery}
 */
jQuery.prototype.wrap = function(arg1) {};
 
/**
 * @param {(string|jQuerySelector|Element|jQuery)} wrappingElement
 * @return {!jQuery}
 */
jQuery.prototype.wrapAll = function(wrappingElement) {};
 
/**
 * @param {(string|jQuerySelector|Element|jQuery|function(number))} arg1
 * @return {!jQuery}
 */
jQuery.prototype.wrapInner = function(arg1) {};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/oli.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/oli.js

Statements: 3.23% (2 / 62)      Branches: 100% (0 / 0)      Functions: 0% (0 / 21)      Lines: 3.23% (2 / 62)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376                2           2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  
/**
 * @externs
 */
 
 
/**
 * @type {Object}
 */
var oli;
 
 
/**
 * @interface
 */
oli.AssertionError = function() {};
 
 
/**
 * @type {number}
 */
oli.AssertionError.prototype.code;
 
 
/**
 * @interface
 */
oli.events.Event = function() {};
 
 
/**
 * @type {Object}
 */
oli.events.Event.prototype.target;
 
 
/**
 * @type {string}
 */
oli.events.Event.prototype.type;
 
 
/**
 */
oli.events.Event.prototype.preventDefault = function() {};
 
 
/**
 */
oli.events.Event.prototype.stopPropagation = function() {};
 
 
/**
 * @interface
 */
oli.Collection.Event = function() {};
 
 
/**
 * @type {*}
 */
oli.Collection.Event.prototype.element;
 
 
/**
 * @interface
 */
oli.DragBoxEvent = function() {};
 
 
/**
 * @type {ol.Coordinate}
 */
oli.DragBoxEvent.prototype.coordinate;
 
 
/**
 * @type {ol.MapBrowserEvent}
 */
oli.DragBoxEvent.prototype.mapBrowserEvent;
 
 
/**
 * @interface
 */
oli.DrawEvent = function() {};
 
 
/**
 * @type {ol.Feature}
 */
oli.DrawEvent.prototype.feature;
 
 
/**
 * @interface
 */
oli.ModifyEvent = function() {};
 
 
/**
 * @type {ol.Collection.<ol.Feature>}
 */
oli.ModifyEvent.prototype.features;
 
 
/**
 * @type {ol.MapBrowserEvent}
 */
oli.ModifyEvent.prototype.mapBrowserEvent;
 
 
/**
 * @type {Object}
 */
oli.Object;
 
 
/**
 * @interface
 */
oli.Object.Event = function() {};
 
 
/**
 * @type {string}
 */
oli.Object.Event.prototype.key;
 
 
/**
 * @type {*}
 */
oli.Object.Event.prototype.oldValue;
 
 
/**
 * @interface
 */
oli.MapBrowserEvent = function() {};
 
 
/**
 * @type {ol.Coordinate}
 */
oli.MapBrowserEvent.prototype.coordinate;
 
 
/**
 * @type {Event}
 */
oli.MapBrowserEvent.prototype.originalEvent;
 
 
/**
 * @type {ol.Pixel}
 */
oli.MapBrowserEvent.prototype.pixel;
 
 
/**
 * @type {boolean}
 */
oli.MapBrowserEvent.prototype.dragging;
 
 
/**
 * @interface
 */
oli.MapEvent = function() {};
 
 
/**
 * @type {ol.Map}
 */
oli.MapEvent.prototype.map;
 
 
/**
 * @type {olx.FrameState}
 */
oli.MapEvent.prototype.frameState;
 
 
/**
 * @interface
 */
oli.SelectEvent = function() {};
 
 
/**
 * @type {Array.<ol.Feature>}
 */
oli.SelectEvent.prototype.deselected;
 
 
/**
 * @type {Array.<ol.Feature>}
 */
oli.SelectEvent.prototype.selected;
 
 
/**
 * @type {ol.MapBrowserEvent}
 */
oli.SelectEvent.prototype.mapBrowserEvent;
 
 
/**
 * @type {Object}
 */
oli.control;
 
 
/**
 * @interface
 */
oli.control.Control = function() {};
 
 
/**
 * @param {ol.Map} map Map.
 * @return {undefined} Undefined.
 */
oli.control.Control.prototype.setMap = function(map) {};
 
 
/**
 * @type {Object}
 */
oli.interaction;
 
 
/**
 * @interface
 */
oli.interaction.DragAndDropEvent = function() {};
 
 
/**
 * @type {Array.<ol.Feature>|undefined}
 */
oli.interaction.DragAndDropEvent.prototype.features;
 
 
/**
 * @type {ol.proj.Projection|undefined}
 */
oli.interaction.DragAndDropEvent.prototype.projection;
 
 
/**
 * @type {File}
 */
oli.interaction.DragAndDropEvent.prototype.file;
 
 
/**
 * @interface
 */
oli.interaction.TranslateEvent = function() {};
 
 
/**
 * @type {ol.Collection.<ol.Feature>}
 */
oli.interaction.TranslateEvent.prototype.features;
 
 
/**
 * @type {ol.Coordinate}
 */
oli.interaction.TranslateEvent.prototype.coordinate;
 
 
/**
 * @type {Object}
 */
oli.render;
 
 
/**
 * @interface
 */
oli.render.Event = function() {};
 
 
/**
 * @type {CanvasRenderingContext2D|null|undefined}
 */
oli.render.Event.prototype.context;
 
 
/**
 * @type {olx.FrameState|undefined}
 */
oli.render.Event.prototype.frameState;
 
 
/**
 * @type {ol.webgl.Context|null|undefined}
 */
oli.render.Event.prototype.glContext;
 
 
/**
 * @type {ol.render.VectorContext|undefined}
 */
oli.render.Event.prototype.vectorContext;
 
 
/**
 * @type {Object}
 */
oli.source;
 
 
/**
 * @interface
 */
oli.source.ImageEvent = function() {};
 
 
/**
 * @type {ol.Image}
 */
oli.source.ImageEvent.prototype.image;
 
 
/**
 * @interface
 */
oli.source.RasterEvent = function() {};
 
 
/**
 * @type {ol.Extent}
 */
oli.source.RasterEvent.prototype.extent;
 
 
/**
 * @type {number}
 */
oli.source.RasterEvent.prototype.resolution;
 
 
/**
 * @type {Object}
 */
oli.source.RasterEvent.prototype.data;
 
 
/**
 * @interface
 */
oli.source.Tile.Event = function() {};
 
 
/**
 * @type {ol.Tile}
 */
oli.source.Tile.Event.prototype.tile;
 
 
/**
 * @interface
 */
oli.source.Vector.Event = function() {};
 
 
/**
 * @type {ol.Feature|undefined}
 */
oli.source.Vector.Event.prototype.feature;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/olx.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/olx.js

Statements: 0.24% (2 / 840)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 0.24% (2 / 840)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 4683 4684 4685 4686 4687 4688 4689 4690 4691 4692 4693 4694 4695 4696 4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772 4773 4774 4775 4776 4777 4778 4779 4780 4781 4782 4783 4784 4785 4786 4787 4788 4789 4790 4791 4792 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831 4832 4833 4834 4835 4836 4837 4838 4839 4840 4841 4842 4843 4844 4845 4846 4847 4848 4849 4850 4851 4852 4853 4854 4855 4856 4857 4858 4859 4860 4861 4862 4863 4864 4865 4866 4867 4868 4869 4870 4871 4872 4873 4874 4875 4876 4877 4878 4879 4880 4881 4882 4883 4884 4885 4886 4887 4888 4889 4890 4891 4892 4893 4894 4895 4896 4897 4898 4899 4900 4901 4902 4903 4904 4905 4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 5008 5009 5010 5011 5012 5013 5014 5015 5016 5017 5018 5019 5020 5021 5022 5023 5024 5025 5026 5027 5028 5029 5030 5031 5032 5033 5034 5035 5036 5037 5038 5039 5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 5115 5116 5117 5118 5119 5120 5121 5122 5123 5124 5125 5126 5127 5128 5129 5130 5131 5132 5133 5134 5135 5136 5137 5138 5139 5140 5141 5142 5143 5144 5145 5146 5147 5148 5149 5150 5151 5152 5153 5154 5155 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 5175 5176 5177 5178 5179 5180 5181 5182 5183 5184 5185 5186 5187 5188 5189 5190 5191 5192 5193 5194 5195 5196 5197 5198 5199 5200 5201 5202 5203 5204 5205 5206 5207 5208 5209 5210 5211 5212 5213 5214 5215 5216 5217 5218 5219 5220 5221 5222 5223 5224 5225 5226 5227 5228 5229 5230 5231 5232 5233 5234 5235 5236 5237 5238 5239 5240 5241 5242 5243 5244 5245 5246 5247 5248 5249 5250 5251 5252 5253 5254 5255 5256 5257 5258 5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282 5283 5284 5285 5286 5287 5288 5289 5290 5291 5292 5293 5294 5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406 5407 5408 5409 5410 5411 5412 5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 5813 5814 5815 5816 5817 5818 5819 5820 5821 5822 5823 5824 5825 5826 5827 5828 5829 5830 5831 5832 5833 5834 5835 5836 5837 5838 5839 5840 5841 5842 5843 5844 5845 5846 5847 5848 5849 5850 5851 5852 5853 5854 5855 5856 5857 5858 5859 5860 5861 5862 5863 5864 5865 5866 5867 5868 5869 5870 5871 5872 5873 5874 5875 5876 5877 5878 5879 5880 5881 5882 5883 5884 5885 5886 5887 5888 5889 5890 5891 5892 5893 5894 5895 5896 5897 5898 5899 5900 5901 5902 5903 5904 5905 5906 5907 5908 5909 5910 5911 5912 5913 5914 5915 5916 5917 5918 5919 5920 5921 5922 5923 5924 5925 5926 5927 5928 5929 5930 5931 5932 5933 5934 5935 5936 5937 5938 5939 5940 5941 5942 5943 5944 5945 5946 5947 5948 5949 5950 5951 5952 5953 5954 5955 5956 5957 5958 5959 5960 5961 5962 5963 5964 5965 5966 5967 5968 5969 5970 5971 5972 5973 5974 5975 5976 5977 5978 5979 5980 5981 5982 5983 5984 5985 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 6061 6062 6063 6064 6065 6066 6067 6068 6069 6070 6071 6072 6073 6074 6075 6076 6077 6078 6079 6080 6081 6082 6083 6084 6085 6086 6087 6088 6089 6090 6091 6092 6093 6094 6095 6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129 6130 6131 6132 6133 6134 6135 6136 6137 6138 6139 6140 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 6173 6174 6175 6176 6177 6178 6179 6180 6181 6182 6183 6184 6185 6186 6187 6188 6189 6190 6191 6192 6193 6194 6195 6196 6197 6198 6199 6200 6201 6202 6203 6204 6205 6206 6207 6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227 6228 6229 6230 6231 6232 6233 6234 6235 6236 6237 6238 6239 6240 6241 6242 6243 6244 6245 6246 6247 6248 6249 6250 6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265 6266 6267 6268 6269 6270 6271 6272 6273 6274 6275 6276 6277 6278 6279 6280 6281 6282 6283 6284 6285 6286 6287 6288 6289 6290 6291 6292 6293 6294 6295 6296 6297 6298 6299 6300 6301 6302 6303 6304 6305 6306 6307 6308 6309 6310 6311 6312 6313 6314 6315 6316 6317 6318 6319 6320 6321 6322 6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 6347 6348 6349 6350 6351 6352 6353 6354 6355 6356 6357 6358 6359 6360 6361 6362 6363 6364 6365 6366 6367 6368 6369 6370 6371 6372 6373 6374 6375 6376 6377 6378 6379 6380 6381 6382 6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395 6396 6397 6398 6399 6400 6401 6402 6403 6404 6405 6406 6407 6408 6409 6410 6411 6412 6413 6414 6415 6416 6417 6418 6419 6420 6421 6422 6423 6424 6425 6426 6427 6428 6429 6430 6431 6432 6433 6434 6435 6436 6437 6438 6439 6440 6441 6442 6443 6444 6445 6446 6447 6448 6449 6450 6451 6452 6453 6454 6455 6456 6457 6458 6459 6460 6461 6462 6463 6464 6465 6466 6467 6468 6469 6470 6471 6472 6473 6474 6475 6476 6477 6478 6479 6480 6481 6482 6483 6484 6485 6486 6487 6488 6489 6490 6491 6492 6493 6494 6495 6496 6497 6498 6499 6500 6501 6502 6503 6504 6505 6506 6507 6508 6509 6510 6511 6512 6513 6514 6515 6516 6517 6518 6519 6520 6521 6522 6523 6524 6525 6526 6527 6528 6529 6530 6531 6532 6533 6534 6535 6536 6537 6538 6539 6540 6541 6542 6543 6544 6545 6546 6547 6548 6549 6550 6551 6552 6553 6554 6555 6556 6557 6558 6559 6560 6561 6562 6563 6564 6565 6566 6567 6568 6569 6570 6571 6572 6573 6574 6575 6576 6577 6578 6579 6580 6581 6582 6583 6584 6585 6586 6587 6588 6589 6590 6591 6592 6593 6594 6595 6596 6597 6598 6599 6600 6601 6602 6603 6604 6605 6606 6607 6608 6609 6610 6611 6612 6613 6614 6615 6616 6617 6618 6619 6620 6621 6622 6623 6624 6625 6626 6627 6628 6629 6630 6631 6632 6633 6634 6635 6636 6637 6638 6639 6640 6641 6642 6643 6644 6645 6646 6647 6648 6649 6650 6651 6652 6653 6654 6655 6656 6657 6658 6659 6660 6661 6662 6663 6664 6665 6666 6667 6668 6669 6670 6671 6672 6673 6674 6675 6676 6677 6678 6679 6680 6681 6682 6683 6684 6685 6686 6687 6688 6689 6690 6691 6692 6693 6694 6695 6696 6697 6698 6699 6700 6701 6702 6703 6704 6705 6706 6707 6708 6709 6710 6711 6712 6713 6714 6715 6716 6717 6718 6719 6720 6721 6722 6723 6724 6725 6726 6727 6728 6729 6730 6731 6732 6733 6734 6735 6736 6737 6738 6739 6740 6741 6742 6743 6744 6745 6746 6747 6748 6749 6750 6751 6752 6753 6754 6755 6756 6757 6758 6759 6760 6761 6762 6763 6764 6765 6766 6767 6768 6769 6770 6771 6772 6773 6774 6775 6776 6777 6778 6779 6780 6781 6782 6783 6784 6785 6786 6787 6788 6789 6790 6791 6792 6793 6794 6795 6796 6797 6798 6799 6800 6801 6802 6803 6804 6805 6806 6807 6808 6809 6810 6811 6812 6813 6814 6815 6816 6817 6818 6819 6820 6821 6822 6823 6824 6825 6826 6827 6828 6829 6830 6831 6832 6833 6834 6835 6836 6837 6838 6839 6840 6841 6842 6843 6844 6845 6846 6847 6848 6849 6850 6851 6852 6853 6854 6855 6856 6857 6858 6859 6860 6861 6862 6863 6864 6865 6866 6867 6868 6869 6870 6871 6872 6873 6874 6875 6876 6877 6878 6879 6880 6881 6882 6883 6884 6885 6886 6887 6888 6889 6890 6891 6892 6893 6894 6895 6896 6897 6898 6899 6900 6901 6902 6903 6904 6905 6906 6907 6908 6909 6910 6911 6912 6913 6914 6915 6916 6917 6918 6919 6920 6921 6922 6923 6924 6925 6926 6927 6928 6929 6930 6931 6932 6933 6934 6935 6936 6937 6938 6939 6940 6941 6942 6943 6944 6945 6946 6947 6948 6949 6950 6951 6952 6953 6954 6955 6956 6957 6958 6959 6960 6961 6962 6963 6964 6965 6966 6967 6968 6969 6970 6971 6972 6973 6974 6975 6976 6977 6978 6979 6980 6981 6982 6983 6984 6985 6986 6987 6988 6989 6990 6991 6992 6993 6994 6995 6996 6997 6998 6999 7000 7001 7002 7003 7004 7005 7006 7007 7008 7009 7010 7011 7012 7013 7014 7015 7016 7017 7018 7019 7020 7021 7022 7023 7024 7025 7026 7027 7028 7029 7030 7031 7032 7033 7034 7035 7036 7037 7038 7039 7040 7041 7042 7043 7044 7045 7046 7047 7048 7049 7050 7051 7052 7053 7054 7055 7056 7057 7058 7059 7060 7061 7062 7063 7064 7065 7066 7067 7068 7069 7070 7071 7072 7073 7074 7075 7076 7077 7078 7079 7080 7081 7082 7083 7084 7085 7086 7087 7088 7089 7090 7091 7092 7093 7094 7095 7096 7097 7098 7099 7100 7101 7102 7103 7104 7105 7106 7107 7108 7109 7110 7111 7112 7113 7114 7115 7116 7117 7118 7119 7120 7121 7122 7123 7124 7125 7126 7127 7128 7129 7130 7131 7132 7133 7134 7135 7136 7137 7138 7139 7140 7141 7142 7143 7144 7145 7146 7147 7148 7149 7150 7151 7152 7153 7154 7155 7156 7157 7158 7159 7160 7161 7162 7163 7164 7165 7166 7167 7168 7169 7170 7171 7172 7173 7174 7175 7176 7177 7178 7179 7180 7181 7182 7183 7184 7185 7186 7187 7188 7189 7190 7191 7192 7193 7194 7195 7196 7197 7198 7199 7200 7201 7202 7203 7204 7205 7206 7207 7208 7209 7210 7211 7212 7213 7214 7215 7216 7217 7218 7219 7220 7221 7222 7223 7224 7225 7226 7227 7228 7229 7230 7231 7232 7233 7234 7235 7236 7237 7238 7239 7240 7241 7242 7243 7244 7245 7246 7247 7248 7249 7250 7251 7252 7253 7254 7255 7256 7257 7258 7259 7260 7261 7262 7263 7264 7265 7266 7267 7268 7269 7270 7271 7272 7273 7274 7275 7276 7277 7278 7279 7280 7281 7282 7283 7284 7285 7286 7287 7288 7289 7290 7291 7292 7293 7294 7295 7296 7297 7298 7299 7300 7301 7302 7303 7304 7305 7306 7307 7308 7309 7310 7311 7312 7313 7314 7315 7316 7317 7318 7319 7320 7321 7322 7323 7324 7325 7326 7327 7328 7329 7330 7331 7332 7333 7334 7335 7336 7337 7338 7339 7340 7341 7342 7343 7344 7345 7346 7347 7348 7349 7350 7351 7352 7353 7354 7355 7356 7357 7358 7359 7360 7361 7362 7363 7364 7365 7366 7367 7368 7369 7370 7371 7372 7373 7374 7375 7376 7377 7378 7379 7380 7381 7382 7383 7384 7385 7386 7387 7388 7389 7390 7391 7392 7393 7394 7395 7396 7397 7398 7399 7400 7401 7402 7403 7404 7405 7406 7407 7408 7409 7410 7411 7412 7413 7414 7415 7416 7417 7418 7419 7420 7421 7422 7423 7424 7425 7426 7427 7428 7429 7430 7431 7432 7433 7434 7435 7436 7437 7438 7439 7440 7441 7442 7443 7444 7445 7446 7447 7448 7449 7450 7451 7452 7453 7454 7455 7456 7457 7458 7459 7460 7461 7462 7463 7464 7465 7466 7467 7468 7469 7470 7471 7472 7473 7474 7475 7476 7477 7478 7479 7480 7481 7482 7483 7484 7485 7486 7487 7488 7489 7490 7491 7492 7493 7494 7495 7496 7497 7498 7499 7500 7501 7502 7503 7504 7505 7506 7507 7508 7509 7510 7511 7512 7513 7514 7515 7516 7517 7518 7519 7520 7521 7522 7523 7524 7525 7526 7527 7528 7529 7530 7531 7532 7533 7534 7535 7536 7537 7538 7539 7540 7541 7542 7543 7544 7545 7546 7547 7548 7549 7550 7551 7552 7553 7554 7555 7556 7557 7558 7559 7560 7561 7562 7563 7564 7565 7566 7567 7568 7569 7570 7571 7572 7573 7574 7575 7576 7577 7578 7579 7580 7581 7582 7583 7584 7585 7586 7587 7588 7589 7590 7591 7592 7593 7594 7595 7596 7597 7598 7599 7600 7601 7602 7603 7604 7605 7606 7607 7608 7609 7610 7611 7612 7613 7614 7615 7616 7617 7618 7619 7620 7621 7622 7623 7624 7625 7626 7627 7628 7629 7630 7631 7632 7633 7634 7635 7636 7637 7638 7639 7640 7641 7642 7643 7644 7645 7646 7647 7648 7649 7650 7651 7652 7653 7654 7655 7656 7657 7658 7659 7660 7661 7662 7663 7664 7665 7666 7667 7668 7669 7670 7671 7672 7673 7674 7675 7676 7677 7678 7679 7680 7681 7682 7683 7684 7685 7686 7687 7688 7689 7690 7691 7692 7693 7694 7695 7696 7697 7698 7699 7700 7701 7702 7703 7704 7705 7706 7707 7708 7709 7710 7711 7712 7713 7714 7715 7716 7717 7718 7719 7720 7721 7722 7723 7724 7725 7726 7727 7728 7729 7730 7731 7732 7733 7734 7735 7736 7737 7738 7739 7740 7741 7742 7743 7744 7745 7746 7747 7748 7749 7750 7751 7752 7753 7754 7755 7756 7757 7758 7759 7760 7761 7762 7763 7764 7765 7766 7767 7768 7769 7770 7771 7772 7773 7774 7775 7776 7777 7778 7779 7780 7781 7782 7783 7784 7785 7786 7787 7788 7789 7790 7791 7792 7793 7794 7795 7796 7797 7798 7799 7800 7801 7802 7803 7804 7805 7806 7807 7808 7809 7810 7811 7812 7813 7814 7815 7816 7817 7818 7819 7820 7821 7822 7823 7824 7825 7826 7827 7828 7829 7830 7831 7832 7833 7834 7835 7836 7837 7838 7839 7840 7841 7842 7843 7844 7845 7846 7847 7848 7849 7850 7851 7852 7853 7854 7855 7856 7857 7858 7859 7860 7861 7862 7863 7864 7865 7866 7867 7868 7869 7870 7871 7872 7873 7874 7875 7876 7877 7878 7879 7880 7881 7882 7883 7884 7885 7886 7887 7888 7889 7890 7891 7892 7893 7894 7895 7896 7897 7898 7899 7900 7901 7902 7903 7904 7905 7906 7907 7908 7909 7910 7911 7912 7913 7914 7915 7916 7917 7918 7919 7920 7921 7922 7923 7924        2                 2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            
 
/**
 * @type {Object}
 */
var olx;
 
 
/* typedefs for object literals provided by applications */
 
 
/**
 * @typedef {{unique: (boolean|undefined)}}
 */
olx.CollectionOptions;
 
 
/**
 * Disallow the same item from being added to the collection twice.  Default is
 * false.
 * @type {boolean|undefined}
 * @api
 */
olx.CollectionOptions.prototype.unique;
 
 
/**
 * @typedef {{html: string,
 *     tileRanges: (Object.<string, Array.<ol.TileRange>>|undefined)}}
 */
olx.AttributionOptions;
 
 
/**
 * HTML markup for this attribution.
 * @type {string}
 * @api
 */
olx.AttributionOptions.prototype.html;
 
 
/**
 * @typedef {{tracking: (boolean|undefined)}}
 */
olx.DeviceOrientationOptions;
 
 
/**
 * Start tracking. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.DeviceOrientationOptions.prototype.tracking;
 
 
/**
 * @typedef {{tracking: (boolean|undefined),
 *     trackingOptions: (GeolocationPositionOptions|undefined),
 *     projection: ol.ProjectionLike}}
 */
olx.GeolocationOptions;
 
 
/**
 * Start Tracking. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.GeolocationOptions.prototype.tracking;
 
 
/**
 * Tracking options. See
 * {@link http://www.w3.org/TR/geolocation-API/#position_options_interface}.
 * @type {GeolocationPositionOptions|undefined}
 * @api
 */
olx.GeolocationOptions.prototype.trackingOptions;
 
 
/**
 * The projection the position is reported in.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.GeolocationOptions.prototype.projection;
 
 
/**
 * Object literal with config options for the map logo.
 * @typedef {{href: (string), src: (string)}}
 */
olx.LogoOptions;
 
 
/**
 * Link url for the logo. Will be followed when the logo is clicked.
 * @type {string}
 * @api
 */
olx.LogoOptions.prototype.href;
 
 
/**
 * Image src for the logo.
 * @type {string}
 * @api
 */
olx.LogoOptions.prototype.src;
 
 
/**
 * @typedef {{map: (ol.Map|undefined),
 *     maxLines: (number|undefined),
 *     strokeStyle: (ol.style.Stroke|undefined),
 *     targetSize: (number|undefined)}}
 */
olx.GraticuleOptions;
 
 
/**
 * Reference to an `ol.Map` object.
 * @type {ol.Map|undefined}
 * @api
 */
olx.GraticuleOptions.prototype.map;
 
 
/**
 * The maximum number of meridians and parallels from the center of the
 * map. The default value is 100, which means that at most 200 meridians
 * and 200 parallels will be displayed. The default value is appropriate
 * for conformal projections like Spherical Mercator. If you increase
 * the value more lines will be drawn and the drawing performance will
 * decrease.
 * @type {number|undefined}
 * @api
 */
olx.GraticuleOptions.prototype.maxLines;
 
 
/**
 * The stroke style to use for drawing the graticule. If not provided, the
 * lines will be drawn with `rgba(0,0,0,0.2)`, a not fully opaque black.
 *
 * @type {ol.style.Stroke|undefined}
 * @api
 */
olx.GraticuleOptions.prototype.strokeStyle;
 
 
/**
 * The target size of the graticule cells, in pixels. Default
 * value is 100 pixels.
 * @type {number|undefined}
 * @api
 */
olx.GraticuleOptions.prototype.targetSize;
 
 
/**
 * Object literal with config options for interactions.
 * @typedef {{handleEvent: function(ol.MapBrowserEvent):boolean}}
 */
olx.interaction.InteractionOptions;
 
 
/**
 * Method called by the map to notify the interaction that a browser event was
 * dispatched to the map. The function may return `false` to prevent the
 * propagation of the event to other interactions in the map's interactions
 * chain.
 * @type {function(ol.MapBrowserEvent):boolean}
 * @api
 */
olx.interaction.InteractionOptions.prototype.handleEvent;
 
 
/**
 * Object literal with config options for the map.
 * @typedef {{controls: (ol.Collection.<ol.control.Control>|Array.<ol.control.Control>|undefined),
 *     pixelRatio: (number|undefined),
 *     interactions: (ol.Collection.<ol.interaction.Interaction>|Array.<ol.interaction.Interaction>|undefined),
 *     keyboardEventTarget: (Element|Document|string|undefined),
 *     layers: (Array.<ol.layer.Base>|ol.Collection.<ol.layer.Base>|undefined),
 *     loadTilesWhileAnimating: (boolean|undefined),
 *     loadTilesWhileInteracting: (boolean|undefined),
 *     logo: (boolean|string|olx.LogoOptions|Element|undefined),
 *     overlays: (ol.Collection.<ol.Overlay>|Array.<ol.Overlay>|undefined),
 *     renderer: (ol.renderer.Type|Array.<ol.renderer.Type>|undefined),
 *     target: (Element|string|undefined),
 *     view: (ol.View|undefined)}}
 */
olx.MapOptions;
 
 
/**
 * Controls initially added to the map. If not specified,
 * {@link ol.control.defaults ol.control.defaults()} is used.
 * @type {ol.Collection.<ol.control.Control>|Array.<ol.control.Control>|undefined}
 * @api
 */
olx.MapOptions.prototype.controls;
 
 
/**
 * The ratio between physical pixels and device-independent pixels (dips) on the
 * device. If `undefined` then it gets set by using `window.devicePixelRatio`.
 * @type {number|undefined}
 * @api
 */
olx.MapOptions.prototype.pixelRatio;
 
 
/**
 * Interactions that are initially added to the map. If not specified,
 * {@link ol.interaction.defaults ol.interaction.defaults()} is used.
 * @type {ol.Collection.<ol.interaction.Interaction>|Array.<ol.interaction.Interaction>|undefined}
 * @api
 */
olx.MapOptions.prototype.interactions;
 
 
/**
 * The element to listen to keyboard events on. This determines when the
 * `KeyboardPan` and `KeyboardZoom` interactions trigger. For example, if this
 * option is set to `document` the keyboard interactions will always trigger. If
 * this option is not specified, the element the library listens to keyboard
 * events on is the map target (i.e. the user-provided div for the map). If this
 * is not `document` the target element needs to be focused for key events to be
 * emitted, requiring that the target element has a `tabindex` attribute.
 * @type {Element|Document|string|undefined}
 * @api
 */
olx.MapOptions.prototype.keyboardEventTarget;
 
 
/**
 * Layers. If this is not defined, a map with no layers will be rendered. Note
 * that layers are rendered in the order supplied, so if you want, for example,
 * a vector layer to appear on top of a tile layer, it must come after the tile
 * layer.
 * @type {Array.<ol.layer.Base>|ol.Collection.<ol.layer.Base>|undefined}
 * @api
 */
olx.MapOptions.prototype.layers;
 
 
/**
 * When set to true, tiles will be loaded during animations. This may improve
 * the user experience, but can also make animations stutter on devices with
 * slow memory. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.MapOptions.prototype.loadTilesWhileAnimating;
 
 
/**
 * When set to true, tiles will be loaded while interacting with the map. This
 * may improve the user experience, but can also make map panning and zooming
 * choppy on devices with slow memory. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.MapOptions.prototype.loadTilesWhileInteracting;
 
 
/**
 * The map logo. A logo to be displayed on the map at all times. If a string is
 * provided, it will be set as the image source of the logo. If an object is
 * provided, the `src` property should be the URL for an image and the `href`
 * property should be a URL for creating a link. If an element is provided,
 * the element will be used. To disable the map logo, set the option to
 * `false`. By default, the OpenLayers logo is shown.
 * @type {boolean|string|olx.LogoOptions|Element|undefined}
 * @api
 */
olx.MapOptions.prototype.logo;
 
 
/**
 * Overlays initially added to the map. By default, no overlays are added.
 * @type {ol.Collection.<ol.Overlay>|Array.<ol.Overlay>|undefined}
 * @api
 */
olx.MapOptions.prototype.overlays;
 
 
/**
 * Renderer. By default, Canvas and WebGL renderers are tested for support
 * in that order, and the first supported used. Specify a
 * {@link ol.renderer.Type} here to use a specific renderer.
 * Note that the Canvas renderer fully supports vector data, but WebGL can only
 * render Point geometries.
 * @type {ol.renderer.Type|Array.<ol.renderer.Type>|undefined}
 * @api
 */
olx.MapOptions.prototype.renderer;
 
 
/**
 * The container for the map, either the element itself or the `id` of the
 * element. If not specified at construction time, {@link ol.Map#setTarget}
 * must be called for the map to be rendered.
 * @type {Element|string|undefined}
 * @api
 */
olx.MapOptions.prototype.target;
 
 
/**
 * The map's view.  No layer sources will be fetched unless this is specified at
 * construction time or through {@link ol.Map#setView}.
 * @type {ol.View|undefined}
 * @api
 */
olx.MapOptions.prototype.view;
 
 
/**
 * Object literal with options for the {@link ol.Map#forEachFeatureAtPixel} and
 * {@link ol.Map#hasFeatureAtPixel} methods.
 * @typedef {{layerFilter: ((function(ol.layer.Layer): boolean)|undefined),
 *    hitTolerance: (number|undefined)}}
 */
olx.AtPixelOptions;
 
 
/**
 * Layer filter function. The filter function will receive one argument, the
 * {@link ol.layer.Layer layer-candidate} and it should return a boolean value.
 * Only layers which are visible and for which this function returns `true`
 * will be tested for features. By default, all visible layers will be tested.
 * @type {((function(ol.layer.Layer): boolean)|undefined)}
 * @api
 */
olx.AtPixelOptions.prototype.layerFilter;
 
 
/**
 * Hit-detection tolerance in pixels. Pixels inside the radius around the given position
 * will be checked for features. This only works for the canvas renderer and
 * not for WebGL. Default is `0`.
 * @type {number|undefined}
 * @api
 */
olx.AtPixelOptions.prototype.hitTolerance;
 
 
/**
 * Object literal with config options for the overlay.
 * @typedef {{id: (number|string|undefined),
 *     element: (Element|undefined),
 *     offset: (Array.<number>|undefined),
 *     position: (ol.Coordinate|undefined),
 *     positioning: (ol.OverlayPositioning|string|undefined),
 *     stopEvent: (boolean|undefined),
 *     insertFirst: (boolean|undefined),
 *     autoPan: (boolean|undefined),
 *     autoPanAnimation: (olx.OverlayPanOptions|undefined),
 *     autoPanMargin: (number|undefined)}}
 */
olx.OverlayOptions;
 
 
/**
 * Set the overlay id. The overlay id can be used with the
 * {@link ol.Map#getOverlayById} method.
 * @type {number|string|undefined}
 * @api
 */
olx.OverlayOptions.prototype.id;
 
 
/**
 * The overlay element.
 * @type {Element|undefined}
 * @api
 */
olx.OverlayOptions.prototype.element;
 
 
/**
 * Offsets in pixels used when positioning the overlay. The first element in the
 * array is the horizontal offset. A positive value shifts the overlay right.
 * The second element in the array is the vertical offset. A positive value
 * shifts the overlay down. Default is `[0, 0]`.
 * @type {Array.<number>|undefined}
 * @api
 */
olx.OverlayOptions.prototype.offset;
 
 
/**
 * The overlay position in map projection.
 * @type {ol.Coordinate|undefined}
 * @api
 */
olx.OverlayOptions.prototype.position;
 
 
/**
 * Defines how the overlay is actually positioned with respect to its `position`
 * property. Possible values are `'bottom-left'`, `'bottom-center'`,
 * `'bottom-right'`, `'center-left'`, `'center-center'`, `'center-right'`,
 * `'top-left'`, `'top-center'`, and `'top-right'`. Default is `'top-left'`.
 * @type {ol.OverlayPositioning|string|undefined}
 * @api
 */
olx.OverlayOptions.prototype.positioning;
 
 
/**
 * Whether event propagation to the map viewport should be stopped. Default is
 * `true`. If `true` the overlay is placed in the same container as that of the
 * controls (CSS class name `ol-overlaycontainer-stopevent`); if `false` it is
 * placed in the container with CSS class name `ol-overlaycontainer`.
 * @type {boolean|undefined}
 * @api
 */
olx.OverlayOptions.prototype.stopEvent;
 
 
/**
 * Whether the overlay is inserted first in the overlay container, or appended.
 * Default is `true`. If the overlay is placed in the same container as that of
 * the controls (see the `stopEvent` option) you will probably set `insertFirst`
 * to `true` so the overlay is displayed below the controls.
 * @type {boolean|undefined}
 * @api
 */
olx.OverlayOptions.prototype.insertFirst;
 
 
/**
 * If set to `true` the map is panned when calling `setPosition`, so that the
 * overlay is entirely visible in the current viewport.
 * The default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.OverlayOptions.prototype.autoPan;
 
 
/**
 * The animation options used to pan the overlay into view. This animation
 * is only used when `autoPan` is enabled. A `duration` and `easing` may be
 * provided to customize the animation.
 * @type {olx.OverlayPanOptions|undefined}
 * @api
 */
olx.OverlayOptions.prototype.autoPanAnimation;
 
 
/**
 * The margin (in pixels) between the overlay and the borders of the map when
 * autopanning. The default is `20`.
 * @type {number|undefined}
 * @api
 */
olx.OverlayOptions.prototype.autoPanMargin;
 
 
/**
 * @typedef {{
 *   duration: (number|undefined),
 *   easing: (undefined|function(number):number)
 * }}
 */
olx.OverlayPanOptions;
 
 
/**
 * The duration of the animation in milliseconds. Default is `1000`.
 * @type {number|undefined}
 * @api
 */
olx.OverlayPanOptions.prototype.duration;
 
 
/**
 * The easing function to use. Can be an {@link ol.easing} or a custom function.
 * Default is {@link ol.easing.inAndOut}.
 * @type {undefined|function(number):number}
 * @api
 */
olx.OverlayPanOptions.prototype.easing;
 
 
/**
 * Object literal with config options for the projection.
 * @typedef {{code: string,
 *     units: (ol.proj.Units|string|undefined),
 *     extent: (ol.Extent|undefined),
 *     axisOrientation: (string|undefined),
 *     global: (boolean|undefined),
 *     metersPerUnit: (number|undefined),
 *     worldExtent: (ol.Extent|undefined),
 *     getPointResolution: (function(number, ol.Coordinate):number|undefined) }}
 */
olx.ProjectionOptions;
 
 
/**
 * The SRS identifier code, e.g. `EPSG:4326`.
 * @type {string}
 * @api
 */
olx.ProjectionOptions.prototype.code;
 
 
/**
 * Units. Required unless a proj4 projection is defined for `code`.
 * @type {ol.proj.Units|string|undefined}
 * @api
 */
olx.ProjectionOptions.prototype.units;
 
 
/**
 * The validity extent for the SRS.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.ProjectionOptions.prototype.extent;
 
 
/**
 * The axis orientation as specified in Proj4. The default is `enu`.
 * @type {string|undefined}
 * @api
 */
olx.ProjectionOptions.prototype.axisOrientation;
 
 
/**
 * Whether the projection is valid for the whole globe. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.ProjectionOptions.prototype.global;
 
 
/**
 * The meters per unit for the SRS. If not provided, the `units` are used to get
 * the meters per unit from the {@link ol.proj.METERS_PER_UNIT} lookup table.
 * @type {number|undefined}
 * @api
 */
olx.ProjectionOptions.prototype.metersPerUnit;
 
 
/**
 * The world extent for the SRS.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.ProjectionOptions.prototype.worldExtent;
 
 
/**
 * Function to determine resolution at a point. The function is called with a
 * `{number}` view resolution and an `{ol.Coordinate}` as arguments, and returns
 * the `{number}` resolution at the passed coordinate.
 * @type {(function(number, ol.Coordinate):number|undefined)}
 * @api
 */
olx.ProjectionOptions.prototype.getPointResolution;
 
 
/**
 * Object literal with config options for the view.
 * @typedef {{center: (ol.Coordinate|undefined),
 *     constrainRotation: (boolean|number|undefined),
 *     enableRotation: (boolean|undefined),
 *     extent: (ol.Extent|undefined),
 *     minResolution: (number|undefined),
 *     maxResolution: (number|undefined),
 *     minZoom: (number|undefined),
 *     maxZoom: (number|undefined),
 *     projection: ol.ProjectionLike,
 *     resolution: (number|undefined),
 *     resolutions: (Array.<number>|undefined),
 *     rotation: (number|undefined),
 *     zoom: (number|undefined),
 *     zoomFactor: (number|undefined)}}
 */
olx.ViewOptions;
 
 
/**
 * The initial center for the view. The coordinate system for the center is
 * specified with the `projection` option. Default is `undefined`, and layer
 * sources will not be fetched if this is not set.
 * @type {ol.Coordinate|undefined}
 * @api
 */
olx.ViewOptions.prototype.center;
 
 
/**
 * Rotation constraint. `false` means no constraint. `true` means no constraint,
 * but snap to zero near zero. A number constrains the rotation to that number
 * of values. For example, `4` will constrain the rotation to 0, 90, 180, and
 * 270 degrees. The default is `true`.
 * @type {boolean|number|undefined}
 * @api
 */
olx.ViewOptions.prototype.constrainRotation;
 
 
/**
 * Enable rotation. Default is `true`. If `false` a rotation constraint that
 * always sets the rotation to zero is used. The `constrainRotation` option
 * has no effect if `enableRotation` is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.ViewOptions.prototype.enableRotation;
 
 
/**
 * The extent that constrains the center, in other words, center cannot be set
 * outside this extent. Default is `undefined`.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.ViewOptions.prototype.extent;
 
 
/**
 * The maximum resolution used to determine the resolution constraint. It is
 * used together with `minResolution` (or `maxZoom`) and `zoomFactor`. If
 * unspecified it is calculated in such a way that the projection's validity
 * extent fits in a 256x256 px tile. If the projection is Spherical Mercator
 * (the default) then `maxResolution` defaults to `40075016.68557849 / 256 =
 * 156543.03392804097`.
 * @type {number|undefined}
 * @api
 */
olx.ViewOptions.prototype.maxResolution;
 
 
/**
 * The minimum resolution used to determine the resolution constraint.  It is
 * used together with `maxResolution` (or `minZoom`) and `zoomFactor`.  If
 * unspecified it is calculated assuming 29 zoom levels (with a factor of 2).
 * If the projection is Spherical Mercator (the default) then `minResolution`
 * defaults to `40075016.68557849 / 256 / Math.pow(2, 28) =
 * 0.0005831682455839253`.
 * @type {number|undefined}
 * @api
 */
olx.ViewOptions.prototype.minResolution;
 
 
/**
 * The maximum zoom level used to determine the resolution constraint. It is
 * used together with `minZoom` (or `maxResolution`) and `zoomFactor`. Default
 * is `28`.  Note that if `minResolution` is also provided, it is given
 * precedence over `maxZoom`.
 * @type {number|undefined}
 * @api
 */
olx.ViewOptions.prototype.maxZoom;
 
 
/**
 * The minimum zoom level used to determine the resolution constraint. It is
 * used together with `maxZoom` (or `minResolution`) and `zoomFactor`. Default
 * is `0`. Note that if `maxResolution` is also provided, it is given
 * precedence over `minZoom`.
 * @type {number|undefined}
 * @api
 */
olx.ViewOptions.prototype.minZoom;
 
 
/**
 * The projection. Default is `EPSG:3857` (Spherical Mercator).
 * @type {ol.ProjectionLike}
 * @api
 */
olx.ViewOptions.prototype.projection;
 
 
/**
 * The initial resolution for the view. The units are `projection` units per
 * pixel (e.g. meters per pixel). An alternative to setting this is to set
 * `zoom`. Default is `undefined`, and layer sources will not be fetched if
 * neither this nor `zoom` are defined.
 * @type {number|undefined}
 * @api
 */
olx.ViewOptions.prototype.resolution;
 
 
/**
 * Resolutions to determine the resolution constraint. If set the
 * `maxResolution`, `minResolution`, `minZoom`, `maxZoom`, and `zoomFactor`
 * options are ignored.
 * @type {Array.<number>|undefined}
 * @api
 */
olx.ViewOptions.prototype.resolutions;
 
 
/**
 * The initial rotation for the view in radians (positive rotation clockwise).
 * Default is `0`.
 * @type {number|undefined}
 * @api
 */
olx.ViewOptions.prototype.rotation;
 
 
/**
 * Only used if `resolution` is not defined. Zoom level used to calculate the
 * initial resolution for the view. The initial resolution is determined using
 * the `ol.View#constrainResolution` method.
 * @type {number|undefined}
 * @api
 */
olx.ViewOptions.prototype.zoom;
 
 
/**
 * The zoom factor used to determine the resolution constraint.  Default is `2`.
 * @type {number|undefined}
 * @api
 */
olx.ViewOptions.prototype.zoomFactor;
 
 
/**
 * @typedef {{
 *   center: (ol.Coordinate|undefined),
 *   zoom: (number|undefined),
 *   resolution: (number|undefined),
 *   rotation: (number|undefined),
 *   anchor: (ol.Coordinate|undefined),
 *   duration: (number|undefined),
 *   easing: (undefined|function(number):number)
 * }}
 */
olx.AnimationOptions;
 
 
/**
 * The center of the view at the end of the animation.
 * @type {ol.Coordinate|undefined}
 * @api
 */
olx.AnimationOptions.prototype.center;
 
 
/**
 * The zoom level of the view at the end of the animation.  This takes
 * precedence over `resolution`.
 * @type {number|undefined}
 * @api
 */
olx.AnimationOptions.prototype.zoom;
 
 
/**
 * The resolution of the view at the end of the animation.  If `zoom` is also
 * provided, this option will be ignored.
 * @type {number|undefined}
 * @api
 */
olx.AnimationOptions.prototype.resolution;
 
 
/**
 * The rotation of the view at the end of the animation.
 * @type {number|undefined}
 * @api
 */
olx.AnimationOptions.prototype.rotation;
 
 
/**
 * Optional anchor to remained fixed during a rotation or resolution animation.
 * @type {ol.Coordinate|undefined}
 * @api
 */
olx.AnimationOptions.prototype.anchor;
 
 
/**
 * The duration of the animation in milliseconds (defaults to `1000`).
 * @type {number|undefined}
 * @api
 */
olx.AnimationOptions.prototype.duration;
 
 
/**
 * The easing function used during the animation (defaults to {@link ol.easing.inAndOut}).
 * The function will be called for each frame with a number representing a
 * fraction of the animation's duration.  The function should return a number
 * between 0 and 1 representing the progress toward the destination state.
 * @type {undefined|function(number):number}
 * @api
 */
olx.AnimationOptions.prototype.easing;
 
 
/**
 * Namespace.
 * @type {Object}
 */
olx.animation;
 
 
/**
 * @typedef {{resolution: number,
 *     start: (number|undefined),
 *     duration: (number|undefined),
 *     easing: (undefined|function(number):number)}}
 */
olx.animation.BounceOptions;
 
 
/**
 * The resolution to start the bounce from, typically
 * `map.getView().getResolution()`.
 * @type {number}
 * @api
 */
olx.animation.BounceOptions.prototype.resolution;
 
 
/**
 * The start time of the animation. Default is immediately.
 * @type {number|undefined}
 * @api
 */
olx.animation.BounceOptions.prototype.start;
 
 
/**
 * The duration of the animation in milliseconds. Default is `1000`.
 * @type {number|undefined}
 * @api
 */
olx.animation.BounceOptions.prototype.duration;
 
 
/**
 * The easing function to use. Can be an {@link ol.easing} or a custom function.
 * Default is {@link ol.easing.upAndDown}.
 * @type {undefined|function(number):number}
 * @api
 */
olx.animation.BounceOptions.prototype.easing;
 
 
/**
 * @typedef {{source: ol.Coordinate,
 *     start: (number|undefined),
 *     duration: (number|undefined),
 *     easing: (undefined|function(number):number)}}
 */
olx.animation.PanOptions;
 
 
/**
 * The location to start panning from, typically `map.getView().getCenter()`.
 * @type {ol.Coordinate}
 * @api
 */
olx.animation.PanOptions.prototype.source;
 
 
/**
 * The start time of the animation. Default is immediately.
 * @type {number|undefined}
 * @api
 */
olx.animation.PanOptions.prototype.start;
 
 
/**
 * The duration of the animation in milliseconds. Default is `1000`.
 * @type {number|undefined}
 * @api
 */
olx.animation.PanOptions.prototype.duration;
 
 
/**
 * The easing function to use. Can be an {@link ol.easing} or a custom function.
 * Default is {@link ol.easing.inAndOut}.
 * @type {undefined|function(number):number}
 * @api
 */
olx.animation.PanOptions.prototype.easing;
 
 
/**
 * @typedef {{rotation: (number|undefined),
 *     anchor: (ol.Coordinate|undefined),
 *     start: (number|undefined),
 *     duration: (number|undefined),
 *     easing: (undefined|function(number):number)}}
 */
olx.animation.RotateOptions;
 
 
/**
 * The rotation value (in radians) to begin rotating from, typically
 * `map.getView().getRotation()`. If `undefined` then `0` is assumed.
 * @type {number|undefined}
 * @api
 */
olx.animation.RotateOptions.prototype.rotation;
 
 
/**
 * The rotation center/anchor. The map rotates around the center of the view
 * if unspecified.
 * @type {ol.Coordinate|undefined}
 * @api
 */
olx.animation.RotateOptions.prototype.anchor;
 
 
/**
 * The start time of the animation. Default is immediately.
 * @type {number|undefined}
 * @api
 */
olx.animation.RotateOptions.prototype.start;
 
 
/**
 * The duration of the animation in milliseconds. Default is `1000`.
 * @type {number|undefined}
 * @api
 */
olx.animation.RotateOptions.prototype.duration;
 
 
/**
 * The easing function to use. Can be an {@link ol.easing} or a custom function.
 * Default is {@link ol.easing.inAndOut}.
 * @type {undefined|function(number):number}
 * @api
 */
olx.animation.RotateOptions.prototype.easing;
 
 
/**
 * @typedef {{resolution: number,
 *     start: (number|undefined),
 *     duration: (number|undefined),
 *     easing: (undefined|function(number):number)}}
 */
olx.animation.ZoomOptions;
 
 
/**
 * number The resolution to begin zooming from, typically
 * `map.getView().getResolution()`.
 * @type {number}
 * @api
 */
olx.animation.ZoomOptions.prototype.resolution;
 
 
/**
 * The start time of the animation. Default is immediately.
 * @type {number|undefined}
 * @api
 */
olx.animation.ZoomOptions.prototype.start;
 
 
/**
 * The duration of the animation in milliseconds. Default is `1000`.
 * @type {number|undefined}
 * @api
 */
olx.animation.ZoomOptions.prototype.duration;
 
 
/**
 * The easing function to use. Can be an {@link ol.easing} or a custom function.
 * Default is {@link ol.easing.inAndOut}.
 * @type {undefined|function(number):number}
 * @api
 */
olx.animation.ZoomOptions.prototype.easing;
 
 
/**
 * Namespace.
 * @type {Object}
 */
olx.control;
 
 
/**
 * @typedef {{className: (string|undefined),
 *     collapsible: (boolean|undefined),
 *     collapsed: (boolean|undefined),
 *     tipLabel: (string|undefined),
 *     label: (string|Node|undefined),
 *     collapseLabel: (string|Node|undefined),
 *     render: (function(ol.MapEvent)|undefined),
 *     target: (Element|undefined)}}
 */
olx.control.AttributionOptions;
 
 
/**
 * CSS class name. Default is `ol-attribution`.
 * @type {string|undefined}
 * @api
 */
olx.control.AttributionOptions.prototype.className;
 
 
/**
 * Target.
 * @type {Element|undefined}
 * @api
 */
olx.control.AttributionOptions.prototype.target;
 
 
/**
 * Specify if attributions can be collapsed. If you use an OSM source,
 * should be set to `false` — see
 * {@link https://www.openstreetmap.org/copyright OSM Copyright} —
 * Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.control.AttributionOptions.prototype.collapsible;
 
 
/**
 * Specify if attributions should be collapsed at startup. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.control.AttributionOptions.prototype.collapsed;
 
 
/**
 * Text label to use for the button tip. Default is `Attributions`
 * @type {string|undefined}
 * @api
 */
olx.control.AttributionOptions.prototype.tipLabel;
 
 
/**
 * Text label to use for the collapsed attributions button. Default is `i`.
 * Instead of text, also a Node (e.g. a `span` element) can be used.
 * @type {string|Node|undefined}
 * @api
 */
olx.control.AttributionOptions.prototype.label;
 
 
/**
 * Text label to use for the expanded attributions button. Default is `»`.
 * Instead of text, also a Node (e.g. a `span` element) can be used.
 * @type {string|Node|undefined}
 * @api
 */
olx.control.AttributionOptions.prototype.collapseLabel;
 
 
/**
 * Function called when the control should be re-rendered. This is called
 * in a requestAnimationFrame callback.
 * @type {function(ol.MapEvent)|undefined}
 * @api
 */
olx.control.AttributionOptions.prototype.render;
 
 
/**
 * @typedef {{element: (Element|undefined),
 *     render: (function(ol.MapEvent)|undefined),
 *     target: (Element|string|undefined)}}
 */
olx.control.ControlOptions;
 
 
/**
 * The element is the control's container element. This only needs to be
 * specified if you're developing a custom control.
 * @type {Element|undefined}
 * @api
 */
olx.control.ControlOptions.prototype.element;
 
 
/**
 * Function called when the control should be re-rendered. This is called
 * in a requestAnimationFrame callback.
 * @type {function(ol.MapEvent)|undefined}
 * @api
 */
olx.control.ControlOptions.prototype.render;
 
 
/**
 * Specify a target if you want the control to be rendered outside of the map's
 * viewport.
 * @type {Element|string|undefined}
 * @api
 */
olx.control.ControlOptions.prototype.target;
 
 
/**
 * @typedef {{attribution: (boolean|undefined),
 *     attributionOptions: (olx.control.AttributionOptions|undefined),
 *     rotate: (boolean|undefined),
 *     rotateOptions: (olx.control.RotateOptions|undefined),
 *     zoom: (boolean|undefined),
 *     zoomOptions: (olx.control.ZoomOptions|undefined)}}
 */
olx.control.DefaultsOptions;
 
 
/**
 * Attribution. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.control.DefaultsOptions.prototype.attribution;
 
 
/**
 * Attribution options.
 * @type {olx.control.AttributionOptions|undefined}
 * @api
 */
olx.control.DefaultsOptions.prototype.attributionOptions;
 
 
/**
 * Rotate. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.control.DefaultsOptions.prototype.rotate;
 
 
/**
 * Rotate options.
 * @type {olx.control.RotateOptions|undefined}
 * @api
 */
olx.control.DefaultsOptions.prototype.rotateOptions;
 
 
/**
 * Zoom. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.control.DefaultsOptions.prototype.zoom;
 
 
/**
 * Zoom options.
 * @type {olx.control.ZoomOptions|undefined}
 * @api
 */
olx.control.DefaultsOptions.prototype.zoomOptions;
 
 
/**
 * @typedef {{className: (string|undefined),
 *     label: (string|Node|undefined),
 *     labelActive: (string|Node|undefined),
 *     tipLabel: (string|undefined),
 *     keys: (boolean|undefined),
 *     target: (Element|undefined),
 *     source: (Element|string|undefined)}}
 */
olx.control.FullScreenOptions;
 
 
/**
 * CSS class name. Default is `ol-full-screen`.
 * @type {string|undefined}
 * @api
 */
olx.control.FullScreenOptions.prototype.className;
 
 
/**
 * Text label to use for the button. Default is `\u2922` (NORTH EAST AND SOUTH WEST ARROW).
 * Instead of text, also a Node (e.g. a `span` element) can be used.
 * @type {string|Node|undefined}
 * @api
 */
olx.control.FullScreenOptions.prototype.label;
 
 
/**
 * Text label to use for the button when full-screen is active.
 * Default is `\u00d7` (a cross).
 * Instead of text, also a Node (e.g. a `span` element) can be used.
 * @type {string|Node|undefined}
 * @api
 */
olx.control.FullScreenOptions.prototype.labelActive;
 
 
/**
 * Text label to use for the button tip. Default is `Toggle full-screen`
 * @type {string|undefined}
 * @api
 */
olx.control.FullScreenOptions.prototype.tipLabel;
 
 
/**
 * Full keyboard access.
 * @type {boolean|undefined}
 * @api
 */
olx.control.FullScreenOptions.prototype.keys;
 
 
/**
 * Target.
 * @type {Element|undefined}
 * @api
 */
olx.control.FullScreenOptions.prototype.target;
 
/**
 * The element to be displayed fullscreen. When not provided, the element containing the map viewport will be displayed fullscreen.
 * @type {Element|string|undefined}
 * @api
 */
olx.control.FullScreenOptions.prototype.source;
 
/**
 * @typedef {{className: (string|undefined),
 *     coordinateFormat: (ol.CoordinateFormatType|undefined),
 *     projection: ol.ProjectionLike,
 *     render: (function(ol.MapEvent)|undefined),
 *     target: (Element|undefined),
 *     undefinedHTML: (string|undefined)}}
 */
olx.control.MousePositionOptions;
 
 
/**
 * CSS class name. Default is `ol-mouse-position`.
 * @type {string|undefined}
 * @api
 */
olx.control.MousePositionOptions.prototype.className;
 
 
/**
 * Coordinate format.
 * @type {ol.CoordinateFormatType|undefined}
 * @api
 */
olx.control.MousePositionOptions.prototype.coordinateFormat;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.control.MousePositionOptions.prototype.projection;
 
 
/**
 * Function called when the control should be re-rendered. This is called
 * in a requestAnimationFrame callback.
 * @type {function(ol.MapEvent)|undefined}
 * @api
 */
olx.control.MousePositionOptions.prototype.render;
 
 
/**
 * Target.
 * @type {Element|undefined}
 * @api
 */
olx.control.MousePositionOptions.prototype.target;
 
 
/**
 * Markup for undefined coordinates. Default is `` (empty string).
 * @type {string|undefined}
 * @api
 */
olx.control.MousePositionOptions.prototype.undefinedHTML;
 
 
/**
 * @typedef {{collapsed: (boolean|undefined),
 *     collapseLabel: (string|Node|undefined),
 *     collapsible: (boolean|undefined),
 *     label: (string|Node|undefined),
 *     layers: (Array.<ol.layer.Layer>|ol.Collection.<ol.layer.Layer>|undefined),
 *     render: (function(ol.MapEvent)|undefined),
 *     target: (Element|undefined),
 *     tipLabel: (string|undefined),
 *     view: (ol.View|undefined)}}
 */
olx.control.OverviewMapOptions;
 
 
/**
 * Whether the control should start collapsed or not (expanded).
 * Default to `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.control.OverviewMapOptions.prototype.collapsed;
 
 
/**
 * Text label to use for the expanded overviewmap button. Default is `«`.
 * Instead of text, also a Node (e.g. a `span` element) can be used.
 * @type {string|Node|undefined}
 * @api
 */
olx.control.OverviewMapOptions.prototype.collapseLabel;
 
 
/**
 * Whether the control can be collapsed or not. Default to `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.control.OverviewMapOptions.prototype.collapsible;
 
 
/**
 * Text label to use for the collapsed overviewmap button. Default is `»`.
 * Instead of text, also a Node (e.g. a `span` element) can be used.
 * @type {string|Node|undefined}
 * @api
 */
olx.control.OverviewMapOptions.prototype.label;
 
 
/**
 * Layers for the overview map. If not set, then all main map layers are used
 * instead.
 * @type {Array.<ol.layer.Layer>|ol.Collection.<ol.layer.Layer>|undefined}
 * @api
 */
olx.control.OverviewMapOptions.prototype.layers;
 
 
/**
 * Function called when the control should be re-rendered. This is called
 * in a requestAnimationFrame callback.
 * @type {function(ol.MapEvent)|undefined}
 * @api
 */
olx.control.OverviewMapOptions.prototype.render;
 
 
/**
 * Specify a target if you want the control to be rendered outside of the map's
 * viewport.
 * @type {Element|undefined}
 * @api
 */
olx.control.OverviewMapOptions.prototype.target;
 
 
/**
 * Text label to use for the button tip. Default is `Overview map`
 * @type {string|undefined}
 * @api
 */
olx.control.OverviewMapOptions.prototype.tipLabel;
 
 
/**
 * Custom view for the overview map. If not provided, a default view with
 * an EPSG:3857 projection will be used.
 * @type {ol.View|undefined}
 * @api
 */
olx.control.OverviewMapOptions.prototype.view;
 
 
/**
 * @typedef {{className: (string|undefined),
 *     minWidth: (number|undefined),
 *     render: (function(ol.MapEvent)|undefined),
 *     target: (Element|undefined),
 *     units: (ol.control.ScaleLineUnits|string|undefined)}}
 */
olx.control.ScaleLineOptions;
 
 
/**
 * CSS Class name. Default is `ol-scale-line`.
 * @type {string|undefined}
 * @api
 */
olx.control.ScaleLineOptions.prototype.className;
 
 
/**
 * Minimum width in pixels. Default is `64`.
 * @type {number|undefined}
 * @api
 */
olx.control.ScaleLineOptions.prototype.minWidth;
 
 
/**
 * Function called when the control should be re-rendered. This is called
 * in a requestAnimationFrame callback.
 * @type {function(ol.MapEvent)|undefined}
 * @api
 */
olx.control.ScaleLineOptions.prototype.render;
 
 
/**
 * Target.
 * @type {Element|undefined}
 * @api
 */
olx.control.ScaleLineOptions.prototype.target;
 
 
/**
 * Units. Default is `metric`.
 * @type {ol.control.ScaleLineUnits|string|undefined}
 * @api
 */
olx.control.ScaleLineOptions.prototype.units;
 
 
/**
 * @typedef {{duration: (number|undefined),
 *     className: (string|undefined),
 *     label: (string|Element|undefined),
 *     tipLabel: (string|undefined),
 *     target: (Element|undefined),
 *     render: (function(ol.MapEvent)|undefined),
 *     resetNorth: (function()|undefined),
 *     autoHide: (boolean|undefined)}}
 */
olx.control.RotateOptions;
 
 
/**
 * CSS class name. Default is `ol-rotate`.
 * @type {string|undefined}
 * @api
 */
olx.control.RotateOptions.prototype.className;
 
 
/**
 * Text label to use for the rotate button. Default is `⇧`.
 * Instead of text, also a Node (e.g. a `span` element) can be used.
 * @type {string|Element|undefined}
 * @api
 */
olx.control.RotateOptions.prototype.label;
 
 
/**
 * Text label to use for the rotate tip. Default is `Reset rotation`
 * @type {string|undefined}
 * @api
 */
olx.control.RotateOptions.prototype.tipLabel;
 
 
/**
 * Animation duration in milliseconds. Default is `250`.
 * @type {number|undefined}
 * @api
 */
olx.control.RotateOptions.prototype.duration;
 
 
/**
 * Hide the control when rotation is 0. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.control.RotateOptions.prototype.autoHide;
 
 
/**
 * Function called when the control should be re-rendered. This is called
 * in a requestAnimationFrame callback.
 * @type {function(ol.MapEvent)|undefined}
 * @api
 */
olx.control.RotateOptions.prototype.render;
 
 
/**
 * Function called when the control is clicked. This will override the
 * default resetNorth.
 * @type {function()|undefined}
 * @api
 */
olx.control.RotateOptions.prototype.resetNorth;
 
 
/**
 * Target.
 * @type {Element|undefined}
 * @api
 */
olx.control.RotateOptions.prototype.target;
 
 
/**
 * @typedef {{duration: (number|undefined),
 *     className: (string|undefined),
 *     zoomInLabel: (string|Node|undefined),
 *     zoomOutLabel: (string|Node|undefined),
 *     zoomInTipLabel: (string|undefined),
 *     zoomOutTipLabel: (string|undefined),
 *     delta: (number|undefined),
 *     target: (Element|undefined)}}
 */
olx.control.ZoomOptions;
 
 
/**
 * Animation duration in milliseconds. Default is `250`.
 * @type {number|undefined}
 * @api
 */
olx.control.ZoomOptions.prototype.duration;
 
 
/**
 * CSS class name. Default is `ol-zoom`.
 * @type {string|undefined}
 * @api
 */
olx.control.ZoomOptions.prototype.className;
 
 
/**
 * Text label to use for the zoom-in button. Default is `+`.
 * Instead of text, also a Node (e.g. a `span` element) can be used.
 * @type {string|Node|undefined}
 * @api
 */
olx.control.ZoomOptions.prototype.zoomInLabel;
 
 
/**
 * Text label to use for the zoom-out button. Default is `-`.
 * Instead of text, also a Node (e.g. a `span` element) can be used.
 * @type {string|Node|undefined}
 * @api
 */
olx.control.ZoomOptions.prototype.zoomOutLabel;
 
 
/**
 * Text label to use for the button tip. Default is `Zoom in`
 * @type {string|undefined}
 * @api
 */
olx.control.ZoomOptions.prototype.zoomInTipLabel;
 
 
/**
 * Text label to use for the button tip. Default is `Zoom out`
 * @type {string|undefined}
 * @api
 */
olx.control.ZoomOptions.prototype.zoomOutTipLabel;
 
 
/**
 * The zoom delta applied on each click.
 * @type {number|undefined}
 * @api
 */
olx.control.ZoomOptions.prototype.delta;
 
 
/**
 * Target.
 * @type {Element|undefined}
 * @api
 */
olx.control.ZoomOptions.prototype.target;
 
 
/**
 * @typedef {{className: (string|undefined),
 *     duration: (number|undefined),
 *     maxResolution: (number|undefined),
 *     minResolution: (number|undefined),
 *     render: (function(ol.MapEvent)|undefined)}}
 */
olx.control.ZoomSliderOptions;
 
 
/**
 * CSS class name.
 * @type {string|undefined}
 * @api
 */
olx.control.ZoomSliderOptions.prototype.className;
 
 
/**
 * Animation duration in milliseconds. Default is `200`.
 * @type {number|undefined}
 * @api
 */
olx.control.ZoomSliderOptions.prototype.duration;
 
 
/**
 * Maximum resolution.
 * @type {number|undefined}
 * @api
 */
olx.control.ZoomSliderOptions.prototype.maxResolution;
 
 
/**
 * Minimum resolution.
 * @type {number|undefined}
 * @api
 */
olx.control.ZoomSliderOptions.prototype.minResolution;
 
 
/**
 * Function called when the control should be re-rendered. This is called
 * in a requestAnimationFrame callback.
 * @type {function(ol.MapEvent)|undefined}
 * @api
 */
olx.control.ZoomSliderOptions.prototype.render;
 
 
/**
 * @typedef {{className: (string|undefined),
 *     target: (Element|undefined),
 *     label: (string|Node|undefined),
 *     tipLabel: (string|undefined),
 *     extent: (ol.Extent|undefined)}}
 */
olx.control.ZoomToExtentOptions;
 
 
/**
 * Class name. Default is `ol-zoom-extent`.
 * @type {string|undefined}
 * @api
 */
olx.control.ZoomToExtentOptions.prototype.className;
 
 
/**
 * Target.
 * @type {Element|undefined}
 * @api
 */
olx.control.ZoomToExtentOptions.prototype.target;
 
 
/**
 * Text label to use for the button. Default is `E`.
 * Instead of text, also a Node (e.g. a `span` element) can be used.
 * @type {string|Node|undefined}
 * @api
 */
olx.control.ZoomToExtentOptions.prototype.label;
 
 
/**
 * Text label to use for the button tip. Default is `Zoom to extent`
 * @type {string|undefined}
 * @api
 */
olx.control.ZoomToExtentOptions.prototype.tipLabel;
 
 
/**
 * The extent to zoom to. If undefined the validity extent of the view
 * projection is used.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.control.ZoomToExtentOptions.prototype.extent;
 
 
/**
 * Namespace.
 * @type {Object}
 */
olx.format;
 
 
/**
 * @typedef {{dataProjection: ol.ProjectionLike,
 *     featureProjection: ol.ProjectionLike,
 *     rightHanded: (boolean|undefined)}}
 */
olx.format.ReadOptions;
 
 
/**
 * Projection of the data we are reading. If not provided, the projection will
 * be derived from the data (where possible) or the `defaultDataProjection` of
 * the format is assigned (where set). If the projection can not be derived from
 * the data and if no `defaultDataProjection` is set for a format, the features
 * will not be reprojected.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.format.ReadOptions.prototype.dataProjection;
 
 
/**
 * Projection of the feature geometries created by the format reader. If not
 * provided, features will be returned in the `dataProjection`.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.format.ReadOptions.prototype.featureProjection;
 
 
/**
 * @typedef {{dataProjection: ol.ProjectionLike,
 *     featureProjection: ol.ProjectionLike,
 *     rightHanded: (boolean|undefined),
 *     decimals: (number|undefined)}}
 */
olx.format.WriteOptions;
 
 
/**
 * Projection of the data we are writing. If not provided, the
 * `defaultDataProjection` of the format is assigned (where set). If no
 * `defaultDataProjection` is set for a format, the features will be returned
 * in the `featureProjection`.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.format.WriteOptions.prototype.dataProjection;
 
 
/**
 * Projection of the feature geometries that will be serialized by the format
 * writer. If not provided, geometries are assumed to be in the
 * `dataProjection` if that is set; in other words, they are not transformed.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.format.WriteOptions.prototype.featureProjection;
 
 
/**
 * When writing geometries, follow the right-hand rule for linear ring
 * orientation.  This means that polygons will have counter-clockwise exterior
 * rings and clockwise interior rings.  By default, coordinates are serialized
 * as they are provided at construction.  If `true`, the right-hand rule will
 * be applied.  If `false`, the left-hand rule will be applied (clockwise for
 * exterior and counter-clockwise for interior rings).  Note that not all
 * formats support this.  The GeoJSON format does use this property when writing
 * geometries.
 *
 * @type {boolean|undefined}
 * @api
 */
olx.format.WriteOptions.prototype.rightHanded;
 
 
/**
 * Maximum number of decimal places for coordinates. Coordinates are stored
 * internally as floats, but floating-point arithmetic can create coordinates
 * with a large number of decimal places, not generally wanted on output.
 * Set a number here to round coordinates. Can also be used to ensure that
 * coordinates read in can be written back out with the same number of decimals.
 * Default is no rounding.
 *
 * @type {number|undefined}
 * @api
 */
olx.format.WriteOptions.prototype.decimals;
 
 
/**
 * @typedef {{defaultDataProjection: ol.ProjectionLike,
 *     geometryName: (string|undefined),
 *     featureProjection: ol.ProjectionLike}}
 */
olx.format.GeoJSONOptions;
 
 
/**
 * Default data projection. Default is `EPSG:4326`.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.format.GeoJSONOptions.prototype.defaultDataProjection;
 
 
/**
 * Projection for features read or written by the format.  Options passed to
 * read or write methods will take precedence.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.format.GeoJSONOptions.prototype.featureProjection;
 
 
/**
 * Geometry name to use when creating features.
 * @type {string|undefined}
 * @api
 */
olx.format.GeoJSONOptions.prototype.geometryName;
 
 
/**
 * @typedef {{geometryName: (string|undefined)}}
 */
olx.format.EsriJSONOptions;
 
 
/**
 * Geometry name to use when creating features.
 * @type {string|undefined}
 * @api
 */
olx.format.EsriJSONOptions.prototype.geometryName;
 
 
/**
 * @typedef {{featureClass: (function((ol.geom.Geometry|Object.<string, *>)=)|
 *         function(ol.geom.GeometryType,Array.<number>,
 *             (Array.<number>|Array.<Array.<number>>),Object.<string, *>)|
 *         undefined),
 *     geometryName: (string|undefined),
 *     layers: (Array.<string>|undefined),
 *     layerName: (string|undefined)}}
 */
olx.format.MVTOptions;
 
 
/**
 * Class for features returned by {@link ol.format.MVT#readFeatures}. Set to
 * {@link ol.Feature} to get full editing and geometry support at the cost of
 * decreased rendering performance. The default is {@link ol.render.Feature},
 * which is optimized for rendering and hit detection.
 * @type {undefined|function((ol.geom.Geometry|Object.<string, *>)=)|
 *     function(ol.geom.GeometryType,Array.<number>,
 *         (Array.<number>|Array.<Array.<number>>),Object.<string, *>)}
 * @api
 */
olx.format.MVTOptions.prototype.featureClass;
 
 
/**
 * Geometry name to use when creating features. Default is 'geometry'.
 * @type {string|undefined}
 * @api
 */
olx.format.MVTOptions.prototype.geometryName;
 
 
/**
 * Name of the feature attribute that holds the layer name. Default is 'layer'.
 * @type {string|undefined}
 * @api
 */
olx.format.MVTOptions.prototype.layerName;
 
 
/**
 * Layers to read features from. If not provided, features will be read from all
 * layers.
 * @type {Array.<string>|undefined}
 * @api
 */
olx.format.MVTOptions.prototype.layers;
 
 
/**
 * @typedef {{factor: (number|undefined),
 *     geometryLayout: (ol.geom.GeometryLayout|undefined)}}
 */
olx.format.PolylineOptions;
 
 
/**
 * The factor by which the coordinates values will be scaled.
 * Default is `1e5`.
 * @type {number|undefined}
 * @api
 */
olx.format.PolylineOptions.prototype.factor;
 
 
/**
 * Layout of the feature geometries created by the format reader.
 * Default is `ol.geom.GeometryLayout.XY`.
 * @type {ol.geom.GeometryLayout|undefined}
 * @api
 */
olx.format.PolylineOptions.prototype.geometryLayout;
 
 
/**
 * @typedef {{defaultDataProjection: ol.ProjectionLike}}
 */
olx.format.TopoJSONOptions;
 
 
/**
 * Default data projection. Default is `EPSG:4326`.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.format.TopoJSONOptions.prototype.defaultDataProjection;
 
 
/**
 * @typedef {{altitudeMode: (ol.format.IGCZ|undefined)}}
 */
olx.format.IGCOptions;
 
 
/**
 * Altitude mode. Possible values are `barometric`, `gps`, and `none`. Default
 * is `none`.
 * @type {ol.format.IGCZ|undefined}
 * @api
 */
olx.format.IGCOptions.prototype.altitudeMode;
 
 
/**
 * @typedef {{extractStyles: (boolean|undefined),
 *     defaultStyle: (Array.<ol.style.Style>|undefined),
 *     showPointNames: (boolean|undefined),
 *     writeStyles: (boolean|undefined)}}
 */
olx.format.KMLOptions;
 
 
/**
 * Extract styles from the KML. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.format.KMLOptions.prototype.extractStyles;
 
 
/**
 * Show names as labels for placemarks which contain points. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.format.KMLOptions.prototype.showPointNames;
 
 
/**
 * Default style. The default default style is the same as Google Earth.
 * @type {Array.<ol.style.Style>|undefined}
 * @api
 */
olx.format.KMLOptions.prototype.defaultStyle;
 
 
/**
 * Write styles into KML. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.format.KMLOptions.prototype.writeStyles;
 
 
/**
 * @typedef {{featureNS: (Object.<string, string>|string|undefined),
 *     featureType: (Array.<string>|string|undefined),
 *     srsName: string,
 *     surface: (boolean|undefined),
 *     curve: (boolean|undefined),
 *     multiCurve: (boolean|undefined),
 *     multiSurface: (boolean|undefined),
 *     schemaLocation: (string|undefined)}}
 */
olx.format.GMLOptions;
 
 
/**
 * Feature namespace. If not defined will be derived from GML. If multiple
 * feature types have been configured which come from different feature
 * namespaces, this will be an object with the keys being the prefixes used
 * in the entries of featureType array. The values of the object will be the
 * feature namespaces themselves. So for instance there might be a featureType
 * item `topp:states` in the `featureType` array and then there will be a key
 * `topp` in the featureNS object with value `http://www.openplans.org/topp`.
 * @type {Object.<string, string>|string|undefined}
 * @api
 */
olx.format.GMLOptions.prototype.featureNS;
 
 
/**
 * Feature type(s) to parse. If multiple feature types need to be configured
 * which come from different feature namespaces, `featureNS` will be an object
 * with the keys being the prefixes used in the entries of featureType array.
 * The values of the object will be the feature namespaces themselves.
 * So for instance there might be a featureType item `topp:states` and then
 * there will be a key named `topp` in the featureNS object with value
 * `http://www.openplans.org/topp`.
 * @type {Array.<string>|string|undefined}
 * @api
 */
olx.format.GMLOptions.prototype.featureType;
 
 
/**
 * srsName to use when writing geometries.
 * @type {string}
 * @api
 */
olx.format.GMLOptions.prototype.srsName;
 
 
/**
 * Write gml:Surface instead of gml:Polygon elements. This also affects the
 * elements in multi-part geometries. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.format.GMLOptions.prototype.surface;
 
 
/**
 * Write gml:Curve instead of gml:LineString elements. This also affects the
 * elements in multi-part geometries. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.format.GMLOptions.prototype.curve;
 
 
/**
 * Write gml:MultiCurve instead of gml:MultiLineString. Since the latter is
 * deprecated in GML 3, the default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.format.GMLOptions.prototype.multiCurve;
 
 
/**
 * Write gml:multiSurface instead of gml:MultiPolygon. Since the latter is
 * deprecated in GML 3, the default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.format.GMLOptions.prototype.multiSurface;
 
 
/**
 * Optional schemaLocation to use when writing out the GML, this will override
 * the default provided.
 * @type {string|undefined}
 * @api
 */
olx.format.GMLOptions.prototype.schemaLocation;
 
 
/**
 * @typedef {{readExtensions: (function(ol.Feature, Node)|undefined)}}
 */
olx.format.GPXOptions;
 
 
/**
 * Callback function to process `extensions` nodes.
 * To prevent memory leaks, this callback function must
 * not store any references to the node. Note that the `extensions`
 * node is not allowed in GPX 1.0. Moreover, only `extensions`
 * nodes from `wpt`, `rte` and `trk` can be processed, as those are
 * directly mapped to a feature.
 * @type {function(ol.Feature, Node)|undefined}
 * @api
 */
olx.format.GPXOptions.prototype.readExtensions;
 
 
/**
 * @typedef {{featureNS: (Object.<string, string>|string|undefined),
 *     featureType: (Array.<string>|string|undefined),
 *     gmlFormat: (ol.format.GMLBase|undefined),
 *     schemaLocation: (string|undefined)}}
 */
olx.format.WFSOptions;
 
 
/**
 * The namespace URI used for features.
 * @type {Object.<string, string>|string|undefined}
 * @api
 */
olx.format.WFSOptions.prototype.featureNS;
 
 
/**
 * The feature type to parse. Only used for read operations.
 * @type {Array.<string>|string|undefined}
 * @api
 */
olx.format.WFSOptions.prototype.featureType;
 
 
/**
 * The GML format to use to parse the response. Default is `ol.format.GML3`.
 * @type {ol.format.GMLBase|undefined}
 * @api
 */
olx.format.WFSOptions.prototype.gmlFormat;
 
 
/**
 * Optional schemaLocation to use for serialization, this will override the
 * default.
 * @type {string|undefined}
 * @api
 */
olx.format.WFSOptions.prototype.schemaLocation;
 
 
/**
 * @typedef {{featureNS: string,
 *     featurePrefix: string,
 *     featureTypes: Array.<string>,
 *     srsName: (string|undefined),
 *     handle: (string|undefined),
 *     outputFormat: (string|undefined),
 *     maxFeatures: (number|undefined),
 *     geometryName: (string|undefined),
 *     propertyNames: (Array.<string>|undefined),
 *     startIndex: (number|undefined),
 *     count: (number|undefined),
 *     bbox: (ol.Extent|undefined),
 *     filter: (ol.format.filter.Filter|undefined),
 *     resultType: (string|undefined)}}
 */
olx.format.WFSWriteGetFeatureOptions;
 
 
/**
 * The namespace URI used for features.
 * @type {string}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.featureNS;
 
 
/**
 * The prefix for the feature namespace.
 * @type {string}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.featurePrefix;
 
 
/**
 * The feature type names.
 * @type {Array.<string>}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.featureTypes;
 
 
/**
 * SRS name. No srsName attribute will be set on geometries when this is not
 * provided.
 * @type {string|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.srsName;
 
 
/**
 * Handle.
 * @type {string|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.handle;
 
 
/**
 * Output format.
 * @type {string|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.outputFormat;
 
 
/**
 * Maximum number of features to fetch.
 * @type {number|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.maxFeatures;
 
 
/**
 * Geometry name to use in a BBOX filter.
 * @type {string|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.geometryName;
 
 
/**
 * Optional list of property names to serialize.
 * @type {Array.<string>|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.propertyNames;
 
 
/**
 * Start index to use for WFS paging. This is a WFS 2.0 feature backported to
 * WFS 1.1.0 by some Web Feature Services.
 * @type {number|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.startIndex;
 
 
/**
 * Number of features to retrieve when paging. This is a WFS 2.0 feature
 * backported to WFS 1.1.0 by some Web Feature Services. Please note that some
 * Web Feature Services have repurposed `maxfeatures` instead.
 * @type {number|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.count;
 
 
/**
 * Extent to use for the BBOX filter.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.bbox;
 
 
/**
 * Filter condition. See {@link ol.format.filter} for more information.
 * @type {ol.format.filter.Filter|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.filter;
 
 
/**
 * Indicates what response should be returned, E.g. `hits` only includes the
 * `numberOfFeatures` attribute in the response and no features.
 * @type {string|undefined}
 * @api
 */
olx.format.WFSWriteGetFeatureOptions.prototype.resultType;
 
 
/**
 * @typedef {{featureNS: string,
 *     featurePrefix: string,
 *     featureType: string,
 *     srsName: (string|undefined),
 *     handle: (string|undefined),
 *     nativeElements: Array.<Object>,
 *     gmlOptions: (olx.format.GMLOptions|undefined),
 *     version: (string|undefined)}}
 */
olx.format.WFSWriteTransactionOptions;
 
 
/**
 * The namespace URI used for features.
 * @type {string}
 * @api
 */
olx.format.WFSWriteTransactionOptions.prototype.featureNS;
 
 
/**
 * The prefix for the feature namespace.
 * @type {string}
 * @api
 */
olx.format.WFSWriteTransactionOptions.prototype.featurePrefix;
 
 
/**
 * The feature type name.
 * @type {string}
 * @api
 */
olx.format.WFSWriteTransactionOptions.prototype.featureType;
 
 
/**
 * SRS name. No srsName attribute will be set on geometries when this is not
 * provided.
 * @type {string|undefined}
 * @api
 */
olx.format.WFSWriteTransactionOptions.prototype.srsName;
 
 
/**
 * Handle.
 * @type {string|undefined}
 * @api
 */
olx.format.WFSWriteTransactionOptions.prototype.handle;
 
 
/**
 * Native elements. Currently not supported.
 * @type {Array.<Object>}
 * @api
 */
olx.format.WFSWriteTransactionOptions.prototype.nativeElements;
 
 
/**
 * GML options for the WFS transaction writer.
 * @type {olx.format.GMLOptions|undefined}
 * @api
 */
olx.format.WFSWriteTransactionOptions.prototype.gmlOptions;
 
 
/**
 * WFS version to use for the transaction. Can be either `1.0.0` or `1.1.0`.
 * Default is `1.1.0`.
 * @type {string|undefined}
 * @api
 */
olx.format.WFSWriteTransactionOptions.prototype.version;
 
 
/**
 * @typedef {{splitCollection: (boolean|undefined)}}
 */
olx.format.WKTOptions;
 
 
/**
 * Whether to split GeometryCollections into
 * multiple features on reading. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.format.WKTOptions.prototype.splitCollection;
 
 
/**
 * @typedef {{
 *     layers: (Array.<string>|undefined)
 * }}
 */
olx.format.WMSGetFeatureInfoOptions;
 
 
/**
 * If set, only features of the given layers will be returned by the format
 * when read.
 * @type {Array.<string>|undefined}
 * @api
 */
olx.format.WMSGetFeatureInfoOptions.prototype.layers;
 
 
/**
 * Namespace.
 * @type {Object}
 */
olx.interaction;
 
 
/**
 * Interactions for the map. Default is `true` for all options.
 * @typedef {{
 *     altShiftDragRotate: (boolean|undefined),
 *     constrainResolution: (boolean|undefined),
 *     doubleClickZoom: (boolean|undefined),
 *     keyboard: (boolean|undefined),
 *     mouseWheelZoom: (boolean|undefined),
 *     shiftDragZoom: (boolean|undefined),
 *     dragPan: (boolean|undefined),
 *     pinchRotate: (boolean|undefined),
 *     pinchZoom: (boolean|undefined),
 *     zoomDelta: (number|undefined),
 *     zoomDuration: (number|undefined)
 * }}
 */
olx.interaction.DefaultsOptions;
 
 
/**
 * Whether Alt-Shift-drag rotate is desired. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.altShiftDragRotate;
 
 
/**
 * Zoom to the closest integer zoom level after the wheel/trackpad or
 * pinch gesture ends. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.constrainResolution;
 
 
/**
 * Whether double click zoom is desired. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.doubleClickZoom;
 
 
/**
 * Whether keyboard interaction is desired. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.keyboard;
 
 
/**
 * Whether mousewheel zoom is desired. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.mouseWheelZoom;
 
 
/**
 * Whether Shift-drag zoom is desired. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.shiftDragZoom;
 
 
/**
 * Whether drag pan is desired. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.dragPan;
 
 
/**
 * Whether pinch rotate is desired. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.pinchRotate;
 
 
/**
 * Whether pinch zoom is desired. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.pinchZoom;
 
 
/**
 * Zoom delta.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.zoomDelta;
 
 
/**
 * Zoom duration.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DefaultsOptions.prototype.zoomDuration;
 
 
/**
 * @typedef {{duration: (number|undefined),
 *     delta: (number|undefined)}}
 */
olx.interaction.DoubleClickZoomOptions;
 
 
/**
 * Animation duration in milliseconds. Default is `250`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DoubleClickZoomOptions.prototype.duration;
 
 
/**
 * The zoom delta applied on each double click, default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DoubleClickZoomOptions.prototype.delta;
 
 
/**
 * @typedef {{formatConstructors: (Array.<function(new: ol.format.Feature)>|undefined),
 *     projection: ol.ProjectionLike,
 *     target: (Element|undefined)}}
 */
olx.interaction.DragAndDropOptions;
 
 
/**
 * Format constructors.
 * @type {Array.<function(new: ol.format.Feature)>|undefined}
 * @api
 */
olx.interaction.DragAndDropOptions.prototype.formatConstructors;
 
 
/**
 * Target projection. By default, the map's view's projection is used.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.interaction.DragAndDropOptions.prototype.projection;
 
 
/**
 * The element that is used as the drop target, default is the viewport element.
 * @type {Element|undefined}
 * @api
 */
olx.interaction.DragAndDropOptions.prototype.target;
 
 
/**
 * @typedef {{className: (string|undefined),
 *     condition: (ol.EventsConditionType|undefined),
 *     minArea: (number|undefined),
 *     boxEndCondition: (ol.DragBoxEndConditionType|undefined)}}
 */
olx.interaction.DragBoxOptions;
 
 
/**
 * CSS class name for styling the box. The default is `ol-dragbox`.
 * @type {string|undefined}
 * @api
 */
olx.interaction.DragBoxOptions.prototype.className;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * Default is {@link ol.events.condition.always}.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.DragBoxOptions.prototype.condition;
 
 
/**
 * The minimum area of the box in pixel, this value is used by the default
 * `boxEndCondition` function. Default is `64`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DragBoxOptions.prototype.minArea;
 
 
/**
 * A function that takes a {@link ol.MapBrowserEvent} and two
 * {@link ol.Pixel}s to indicate whether a `boxend` event should be fired.
 * Default is `true` if the area of the box is bigger than the `minArea` option.
 * @type {ol.DragBoxEndConditionType|undefined}
 * @api
 */
olx.interaction.DragBoxOptions.prototype.boxEndCondition;
 
 
/**
 * @typedef {{condition: (ol.EventsConditionType|undefined),
 *     kinetic: (ol.Kinetic|undefined)}}
 */
olx.interaction.DragPanOptions;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * Default is {@link ol.events.condition.noModifierKeys}.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.DragPanOptions.prototype.condition;
 
 
/**
 * Kinetic inertia to apply to the pan.
 * @type {ol.Kinetic|undefined}
 * @api
 */
olx.interaction.DragPanOptions.prototype.kinetic;
 
 
/**
 * @typedef {{condition: (ol.EventsConditionType|undefined),
 *     duration: (number|undefined)}}
 */
olx.interaction.DragRotateAndZoomOptions;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * Default is {@link ol.events.condition.shiftKeyOnly}.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.DragRotateAndZoomOptions.prototype.condition;
 
 
/**
 * Animation duration in milliseconds. Default is `400`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DragRotateAndZoomOptions.prototype.duration;
 
 
/**
 * @typedef {{condition: (ol.EventsConditionType|undefined),
 *     duration: (number|undefined)}}
 */
olx.interaction.DragRotateOptions;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * Default is {@link ol.events.condition.altShiftKeysOnly}.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.DragRotateOptions.prototype.condition;
 
 
/**
 * Animation duration in milliseconds. Default is `250`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DragRotateOptions.prototype.duration;
 
 
/**
 * @typedef {{className: (string|undefined),
 *     condition: (ol.EventsConditionType|undefined),
 *     duration: (number|undefined),
 *     out: (boolean|undefined)}}
 */
olx.interaction.DragZoomOptions;
 
 
/**
 * CSS class name for styling the box. The default is `ol-dragzoom`.
 * @type {string|undefined}
 * @api
 */
olx.interaction.DragZoomOptions.prototype.className;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * Default is {@link ol.events.condition.shiftKeyOnly}.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.DragZoomOptions.prototype.condition;
 
 
/**
 * Animation duration in milliseconds. Default is `200`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DragZoomOptions.prototype.duration;
 
 
/**
 * Use interaction for zooming out. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DragZoomOptions.prototype.out;
 
 
/**
 * @typedef {{clickTolerance: (number|undefined),
 *     features: (ol.Collection.<ol.Feature>|undefined),
 *     source: (ol.source.Vector|undefined),
 *     snapTolerance: (number|undefined),
 *     type: ol.geom.GeometryType,
 *     maxPoints: (number|undefined),
 *     minPoints: (number|undefined),
 *     finishCondition: (ol.EventsConditionType|undefined),
 *     style: (ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined),
 *     geometryFunction: (ol.DrawGeometryFunctionType|undefined),
 *     geometryName: (string|undefined),
 *     condition: (ol.EventsConditionType|undefined),
 *     freehand: (boolean|undefined),
 *     freehandCondition: (ol.EventsConditionType|undefined),
 *     wrapX: (boolean|undefined)}}
 */
olx.interaction.DrawOptions;
 
 
/**
 * The maximum distance in pixels between "down" and "up" for a "up" event
 * to be considered a "click" event and actually add a point/vertex to the
 * geometry being drawn.  Default is 6 pixels.  That value was chosen for
 * the draw interaction to behave correctly on mouse as well as on touch
 * devices.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.clickTolerance;
 
 
/**
 * Destination collection for the drawn features.
 * @type {ol.Collection.<ol.Feature>|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.features;
 
 
/**
 * Destination source for the drawn features.
 * @type {ol.source.Vector|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.source;
 
 
/**
 * Pixel distance for snapping to the drawing finish. Default is `12`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.snapTolerance;
 
 
/**
 * Drawing type ('Point', 'LineString', 'Polygon', 'MultiPoint',
 * 'MultiLineString', 'MultiPolygon' or 'Circle').
 * @type {ol.geom.GeometryType}
 * @api
 */
olx.interaction.DrawOptions.prototype.type;
 
 
/**
 * The number of points that can be drawn before a polygon ring or line string
 * is finished. The default is no restriction.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.maxPoints;
 
 
/**
 * The number of points that must be drawn before a polygon ring or line string
 * can be finished. Default is `3` for polygon rings and `2` for line strings.
 * @type {number|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.minPoints;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether the drawing can be finished.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.finishCondition;
 
 
/**
 * Style for sketch features.
 * @type {ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.style;
 
 
/**
 * Function that is called when a geometry's coordinates are updated.
 * @type {ol.DrawGeometryFunctionType|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.geometryFunction;
 
 
/**
 * Geometry name to use for features created by the draw interaction.
 * @type {string|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.geometryName;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * By default {@link ol.events.condition.noModifierKeys}, i.e. a click, adds a
 * vertex or deactivates freehand drawing.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.condition;
 
 
/**
 * Operate in freehand mode for lines, polygons, and circles.  This makes the
 * interaction always operate in freehand mode and takes precedence over any
 * `freehandCondition` option.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.freehand;
 
 
/**
 * Condition that activates freehand drawing for lines and polygons. This
 * function takes an {@link ol.MapBrowserEvent} and returns a boolean to
 * indicate whether that event should be handled. The default is
 * {@link ol.events.condition.shiftKeyOnly}, meaning that the Shift key
 * activates freehand drawing.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.freehandCondition;
 
 
/**
 * Wrap the world horizontally on the sketch overlay. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.DrawOptions.prototype.wrapX;
 
 
/**
 * @typedef {{extent: (ol.Extent|undefined),
 *     boxStyle: (ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined),
 *     pointerStyle: (ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined),
 *     wrapX: (boolean|undefined)}}
 * @api
 */
olx.interaction.ExtentOptions;
 
/**
 * Initial extent. Defaults to no inital extent
 * @type {ol.Extent|undefined}
 * @api
 */
olx.interaction.ExtentOptions.prototype.extent;
 
/**
 * Style for the drawn extent box.
 * Defaults to ol.style.Style.createDefaultEditing()[ol.geom.GeometryType.POLYGON]
 * @type {ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined}
 * @api
 */
olx.interaction.ExtentOptions.prototype.boxStyle;
 
/**
 * Style for the cursor used to draw the extent.
 * Defaults to ol.style.Style.createDefaultEditing()[ol.geom.GeometryType.POINT]
 * @type {ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined}
 * @api
 */
olx.interaction.ExtentOptions.prototype.pointerStyle;
 
/**
 * Wrap the drawn extent across multiple maps in the X direction?
 * Only affects visuals, not functionality. Defaults to false.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.ExtentOptions.prototype.wrapX;
 
 
/**
 * @typedef {{
 *     features: (ol.Collection.<ol.Feature>|undefined),
 *     layers: (undefined|Array.<ol.layer.Layer>|function(ol.layer.Layer): boolean),
 *     hitTolerance: (number|undefined)
 * }}
 */
olx.interaction.TranslateOptions;
 
 
/**
 * Only features contained in this collection will be able to be translated. If
 * not specified, all features on the map will be able to be translated.
 * @type {ol.Collection.<ol.Feature>|undefined}
 * @api
 */
olx.interaction.TranslateOptions.prototype.features;
 
 
/**
 * A list of layers from which features should be
 * translated. Alternatively, a filter function can be provided. The
 * function will be called for each layer in the map and should return
 * `true` for layers that you want to be translatable. If the option is
 * absent, all visible layers will be considered translatable.
 * @type {undefined|Array.<ol.layer.Layer>|function(ol.layer.Layer): boolean}
 * @api
 */
olx.interaction.TranslateOptions.prototype.layers;
 
 
/**
 * Hit-detection tolerance. Pixels inside the radius around the given position
 * will be checked for features. This only works for the canvas renderer and
 * not for WebGL.
 * @type {number|undefined}
 * @api
 */
olx.interaction.TranslateOptions.prototype.hitTolerance;
 
 
/**
 * @typedef {{condition: (ol.EventsConditionType|undefined),
 *     duration: (number|undefined),
 *     pixelDelta: (number|undefined)}}
 */
olx.interaction.KeyboardPanOptions;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * Default is {@link ol.events.condition.noModifierKeys} and
 * {@link ol.events.condition.targetNotEditable}.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.KeyboardPanOptions.prototype.condition;
 
 
/**
 * Animation duration in milliseconds. Default is `100`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.KeyboardPanOptions.prototype.duration;
 
 
/**
 * Pixel The amount to pan on each key press. Default is `128` pixels.
 * @type {number|undefined}
 * @api
 */
olx.interaction.KeyboardPanOptions.prototype.pixelDelta;
 
 
/**
 * @typedef {{duration: (number|undefined),
 *     condition: (ol.EventsConditionType|undefined),
 *     delta: (number|undefined)}}
 */
olx.interaction.KeyboardZoomOptions;
 
 
/**
 * Animation duration in milliseconds. Default is `100`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.KeyboardZoomOptions.prototype.duration;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * Default is {@link ol.events.condition.targetNotEditable}.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.KeyboardZoomOptions.prototype.condition;
 
 
/**
 * The amount to zoom on each key press. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.KeyboardZoomOptions.prototype.delta;
 
 
/**
 * @typedef {{condition: (ol.EventsConditionType|undefined),
 *     deleteCondition: (ol.EventsConditionType|undefined),
 *     pixelTolerance: (number|undefined),
 *     style: (ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined),
 *     features: ol.Collection.<ol.Feature>,
 *     wrapX: (boolean|undefined)}}
 */
olx.interaction.ModifyOptions;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event will be considered to add or move a vertex
 * to the sketch.
 * Default is {@link ol.events.condition.primaryAction}.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.ModifyOptions.prototype.condition;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * By default, {@link ol.events.condition.singleClick} with
 * {@link ol.events.condition.noModifierKeys} results in a vertex deletion.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.ModifyOptions.prototype.deleteCondition;
 
 
/**
 * Pixel tolerance for considering the pointer close enough to a segment or
 * vertex for editing. Default is `10`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.ModifyOptions.prototype.pixelTolerance;
 
 
/**
 * Style used for the features being modified. By default the default edit
 * style is used (see {@link ol.style}).
 * @type {ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined}
 * @api
 */
olx.interaction.ModifyOptions.prototype.style;
 
 
/**
 * The features the interaction works on.
 * @type {ol.Collection.<ol.Feature>}
 * @api
 */
olx.interaction.ModifyOptions.prototype.features;
 
 
/**
 * Wrap the world horizontally on the sketch overlay. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.ModifyOptions.prototype.wrapX;
 
 
/**
 * @typedef {{constrainResolution: (boolean|undefined),
 *     duration: (number|undefined),
 *     timeout: (number|undefined),
 *     useAnchor: (boolean|undefined)}}
 */
olx.interaction.MouseWheelZoomOptions;
 
 
/**
 * Animation duration in milliseconds. Default is `250`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.MouseWheelZoomOptions.prototype.duration;
 
 
/**
 * Mouse wheel timeout duration in milliseconds. Default is `80`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.MouseWheelZoomOptions.prototype.timeout;
 
 
/**
 * When using a trackpad or magic mouse, zoom to the closest integer zoom level
 * after the scroll gesture ends.
 * Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.MouseWheelZoomOptions.prototype.constrainResolution;
 
 
/**
 * Enable zooming using the mouse's location as the anchor. Default is `true`.
 * When set to false, zooming in and out will zoom to the center of the screen
 * instead of zooming on the mouse's location.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.MouseWheelZoomOptions.prototype.useAnchor;
 
 
/**
 * @typedef {{threshold: (number|undefined),
 *     duration: (number|undefined)}}
 */
olx.interaction.PinchRotateOptions;
 
 
/**
 * The duration of the animation in milliseconds. Default is `250`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.PinchRotateOptions.prototype.duration;
 
 
/**
 * Minimal angle in radians to start a rotation. Default is `0.3`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.PinchRotateOptions.prototype.threshold;
 
 
/**
 * @typedef {{
 *     duration: (number|undefined),
 *     constrainResolution: (boolean|undefined)
 * }}
 */
olx.interaction.PinchZoomOptions;
 
 
/**
 * Animation duration in milliseconds. Default is `400`.
 * @type {number|undefined}
 * @api
 */
olx.interaction.PinchZoomOptions.prototype.duration;
 
/**
 * Zoom to the closest integer zoom level after the pinch gesture ends. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.PinchZoomOptions.prototype.constrainResolution;
 
 
/**
 * @typedef {{handleDownEvent: (function(ol.MapBrowserPointerEvent):boolean|undefined),
 *     handleDragEvent: (function(ol.MapBrowserPointerEvent)|undefined),
 *     handleEvent: (function(ol.MapBrowserEvent):boolean|undefined),
 *     handleMoveEvent: (function(ol.MapBrowserPointerEvent)|undefined),
 *     handleUpEvent: (function(ol.MapBrowserPointerEvent):boolean|undefined)}}
 */
olx.interaction.PointerOptions;
 
 
/**
 * Function handling "down" events. If the function returns `true` then a drag
 * sequence is started.
 * @type {(function(ol.MapBrowserPointerEvent):boolean|undefined)}
 * @api
 */
olx.interaction.PointerOptions.prototype.handleDownEvent;
 
 
/**
 * Function handling "drag" events. This function is called on "move" events
 * during a drag sequence.
 * @type {(function(ol.MapBrowserPointerEvent)|undefined)}
 * @api
 */
olx.interaction.PointerOptions.prototype.handleDragEvent;
 
 
/**
 * Method called by the map to notify the interaction that a browser event was
 * dispatched to the map. The function may return `false` to prevent the
 * propagation of the event to other interactions in the map's interactions
 * chain.
 * @type {(function(ol.MapBrowserEvent):boolean|undefined)}
 * @api
 */
olx.interaction.PointerOptions.prototype.handleEvent;
 
 
/**
 * Function handling "move" events. This function is called on "move" events,
 * also during a drag sequence (so during a drag sequence both the
 * `handleDragEvent` function and this function are called).
 * @type {(function(ol.MapBrowserPointerEvent)|undefined)}
 * @api
 */
olx.interaction.PointerOptions.prototype.handleMoveEvent;
 
 
/**
 * Function handling "up" events. If the function returns `false` then the
 * current drag sequence is stopped.
 * @type {(function(ol.MapBrowserPointerEvent):boolean|undefined)}
 * @api
 */
olx.interaction.PointerOptions.prototype.handleUpEvent;
 
 
/**
 * @typedef {{addCondition: (ol.EventsConditionType|undefined),
 *     condition: (ol.EventsConditionType|undefined),
 *     layers: (undefined|Array.<ol.layer.Layer>|function(ol.layer.Layer): boolean),
 *     style: (ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined),
 *     removeCondition: (ol.EventsConditionType|undefined),
 *     toggleCondition: (ol.EventsConditionType|undefined),
 *     multi: (boolean|undefined),
 *     features: (ol.Collection.<ol.Feature>|undefined),
 *     filter: (ol.SelectFilterFunction|undefined),
 *     wrapX: (boolean|undefined),
 *     hitTolerance: (number|undefined)}}
 */
olx.interaction.SelectOptions;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * By default, this is {@link ol.events.condition.never}. Use this if you want
 * to use different events for add and remove instead of `toggle`.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.SelectOptions.prototype.addCondition;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * This is the event for the selected features as a whole. By default, this is
 * {@link ol.events.condition.singleClick}. Clicking on a feature selects that
 * feature and removes any that were in the selection. Clicking outside any
 * feature removes all from the selection.
 * See `toggle`, `add`, `remove` options for adding/removing extra features to/
 * from the selection.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.SelectOptions.prototype.condition;
 
 
/**
 * A list of layers from which features should be
 * selected. Alternatively, a filter function can be provided. The
 * function will be called for each layer in the map and should return
 * `true` for layers that you want to be selectable. If the option is
 * absent, all visible layers will be considered selectable.
 * @type {undefined|Array.<ol.layer.Layer>|function(ol.layer.Layer): boolean}
 * @api
 */
olx.interaction.SelectOptions.prototype.layers;
 
 
/**
 * Style for the selected features. By default the default edit style is used
 * (see {@link ol.style}).
 * @type {ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined}
 * @api
 */
olx.interaction.SelectOptions.prototype.style;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * By default, this is {@link ol.events.condition.never}. Use this if you want
 * to use different events for add and remove instead of `toggle`.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.SelectOptions.prototype.removeCondition;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a boolean
 * to indicate whether that event should be handled.
 * This is in addition to the `condition` event. By default,
 * {@link ol.events.condition.shiftKeyOnly}, i.e. pressing `shift` as well as
 * the `condition` event, adds that feature to the current selection if it is
 * not currently selected, and removes it if it is.
 * See `add` and `remove` if you want to use different events instead of a
 * toggle.
 * @type {ol.EventsConditionType|undefined}
 * @api
 */
olx.interaction.SelectOptions.prototype.toggleCondition;
 
 
/**
 * A boolean that determines if the default behaviour should select only
 * single features or all (overlapping) features at the clicked map
 * position. Default is false i.e single select
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.SelectOptions.prototype.multi;
 
/**
 * Collection where the interaction will place selected features. Optional. If
 * not set the interaction will create a collection. In any case the collection
 * used by the interaction is returned by
 * {@link ol.interaction.Select#getFeatures}.
 * @type {ol.Collection.<ol.Feature>|undefined}
 * @api
 */
olx.interaction.SelectOptions.prototype.features;
 
/**
 * A function that takes an {@link ol.Feature} and an {@link ol.layer.Layer} and
 * returns `true` if the feature may be selected or `false` otherwise.
 * @type {ol.SelectFilterFunction|undefined}
 * @api
 */
olx.interaction.SelectOptions.prototype.filter;
 
 
/**
 * Wrap the world horizontally on the selection overlay. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.SelectOptions.prototype.wrapX;
 
 
/**
 * Hit-detection tolerance. Pixels inside the radius around the given position
 * will be checked for features. This only works for the canvas renderer and
 * not for WebGL.
 * @type {number|undefined}
 * @api
 */
olx.interaction.SelectOptions.prototype.hitTolerance;
 
 
/**
 * Options for snap
 * @typedef {{
 *     features: (ol.Collection.<ol.Feature>|undefined),
 *     pixelTolerance: (number|undefined),
 *     source: (ol.source.Vector|undefined),
 *     edge: (boolean|undefined),
 *     vertex: (boolean|undefined)
 * }}
 */
olx.interaction.SnapOptions;
 
 
/**
 * Snap to these features. Either this option or source should be provided.
 * @type {ol.Collection.<ol.Feature>|undefined}
 * @api
 */
olx.interaction.SnapOptions.prototype.features;
 
/**
 * Snap to edges. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.SnapOptions.prototype.edge;
 
 
/**
 * Snap to vertices. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.interaction.SnapOptions.prototype.vertex;
 
 
/**
 * Pixel tolerance for considering the pointer close enough to a segment or
 * vertex for snapping. Default is `10` pixels.
 * @type {number|undefined}
 * @api
 */
olx.interaction.SnapOptions.prototype.pixelTolerance;
 
 
/**
 * Snap to features from this source. Either this option or features should be provided
 * @type {ol.source.Vector|undefined}
 * @api
 */
olx.interaction.SnapOptions.prototype.source;
 
 
/**
 * Namespace.
 * @type {Object}
 */
olx.layer;
 
 
/**
 * @typedef {{opacity: (number|undefined),
 *     visible: (boolean|undefined),
 *     extent: (ol.Extent|undefined),
 *     zIndex: (number|undefined),
 *     minResolution: (number|undefined),
 *     maxResolution: (number|undefined)}}
 */
olx.layer.BaseOptions;
 
 
/**
 * Opacity (0, 1). Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.layer.BaseOptions.prototype.opacity;
 
 
/**
 * Visibility. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.layer.BaseOptions.prototype.visible;
 
 
/**
 * The bounding extent for layer rendering.  The layer will not be rendered
 * outside of this extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.layer.BaseOptions.prototype.extent;
 
 
/**
 * The z-index for layer rendering.  At rendering time, the layers will be
 * ordered, first by Z-index and then by position. The default Z-index is 0.
 * @type {number|undefined}
 * @api
 */
olx.layer.BaseOptions.prototype.zIndex;
 
 
/**
 * The minimum resolution (inclusive) at which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.BaseOptions.prototype.minResolution;
 
 
/**
 * The maximum resolution (exclusive) below which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.BaseOptions.prototype.maxResolution;
 
 
/**
 * @typedef {{opacity: (number|undefined),
 *     source: (ol.source.Source|undefined),
 *     visible: (boolean|undefined),
 *     extent: (ol.Extent|undefined),
 *     zIndex: (number|undefined),
 *     minResolution: (number|undefined),
 *     maxResolution: (number|undefined)}}
 */
olx.layer.LayerOptions;
 
 
/**
 * Opacity (0, 1). Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.layer.LayerOptions.prototype.opacity;
 
 
/**
 * Source for this layer.  If not provided to the constructor, the source can
 * be set by calling {@link ol.layer.Layer#setSource layer.setSource(source)}
 * after construction.
 * @type {ol.source.Source|undefined}
 * @api
 */
olx.layer.LayerOptions.prototype.source;
 
 
/**
 * Visibility. Default is `true` (visible).
 * @type {boolean|undefined}
 * @api
 */
olx.layer.LayerOptions.prototype.visible;
 
 
/**
 * The bounding extent for layer rendering.  The layer will not be rendered
 * outside of this extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.layer.LayerOptions.prototype.extent;
 
 
/**
 * The z-index for layer rendering.  At rendering time, the layers will be
 * ordered, first by Z-index and then by position. The default Z-index is 0.
 * @type {number|undefined}
 * @api
 */
olx.layer.LayerOptions.prototype.zIndex;
 
 
/**
 * The minimum resolution (inclusive) at which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.LayerOptions.prototype.minResolution;
 
 
/**
 * The maximum resolution (exclusive) below which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.LayerOptions.prototype.maxResolution;
 
 
/**
 * @typedef {{opacity: (number|undefined),
 *     visible: (boolean|undefined),
 *     extent: (ol.Extent|undefined),
 *     zIndex: (number|undefined),
 *     minResolution: (number|undefined),
 *     maxResolution: (number|undefined),
 *     layers: (Array.<ol.layer.Base>|ol.Collection.<ol.layer.Base>|undefined)}}
 */
olx.layer.GroupOptions;
 
 
/**
 * Opacity (0, 1). Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.layer.GroupOptions.prototype.opacity;
 
 
/**
 * Visibility. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.layer.GroupOptions.prototype.visible;
 
 
/**
 * The bounding extent for layer rendering.  The layer will not be rendered
 * outside of this extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.layer.GroupOptions.prototype.extent;
 
 
/**
 * The z-index for layer rendering.  At rendering time, the layers will be
 * ordered, first by Z-index and then by position. The default Z-index is 0.
 * @type {number|undefined}
 * @api
 */
olx.layer.GroupOptions.prototype.zIndex;
 
 
/**
 * The minimum resolution (inclusive) at which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.GroupOptions.prototype.minResolution;
 
 
/**
 * The maximum resolution (exclusive) below which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.GroupOptions.prototype.maxResolution;
 
 
/**
 * Child layers.
 * @type {Array.<ol.layer.Base>|ol.Collection.<ol.layer.Base>|undefined}
 * @api
 */
olx.layer.GroupOptions.prototype.layers;
 
 
/**
 * @typedef {{gradient: (Array.<string>|undefined),
 *     radius: (number|undefined),
 *     blur: (number|undefined),
 *     shadow: (number|undefined),
 *     weight: (string|function(ol.Feature):number|undefined),
 *     extent: (ol.Extent|undefined),
 *     minResolution: (number|undefined),
 *     maxResolution: (number|undefined),
 *     opacity: (number|undefined),
 *     source: (ol.source.Vector|undefined),
 *     visible: (boolean|undefined)}}
 */
olx.layer.HeatmapOptions;
 
 
/**
 * The color gradient of the heatmap, specified as an array of CSS color
 * strings. Default is `['#00f', '#0ff', '#0f0', '#ff0', '#f00']`.
 * @type {Array.<string>|undefined}
 * @api
 */
olx.layer.HeatmapOptions.prototype.gradient;
 
 
/**
 * Radius size in pixels. Default is `8`.
 * @type {number|undefined}
 * @api
 */
olx.layer.HeatmapOptions.prototype.radius;
 
 
/**
 * Blur size in pixels. Default is `15`.
 * @type {number|undefined}
 * @api
 */
olx.layer.HeatmapOptions.prototype.blur;
 
 
/**
 * Shadow size in pixels. Default is `250`.
 * @type {number|undefined}
 * @api
 */
olx.layer.HeatmapOptions.prototype.shadow;
 
 
/**
 * The feature attribute to use for the weight or a function that returns a
 * weight from a feature. Weight values should range from 0 to 1 (and values
 * outside will be clamped to that range). Default is `weight`.
 * @type {string|function(ol.Feature):number|undefined}
 * @api
 */
olx.layer.HeatmapOptions.prototype.weight;
 
 
/**
 * The bounding extent for layer rendering.  The layer will not be rendered
 * outside of this extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.layer.HeatmapOptions.prototype.extent;
 
 
/**
 * The minimum resolution (inclusive) at which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.HeatmapOptions.prototype.minResolution;
 
 
/**
 * The maximum resolution (exclusive) below which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.HeatmapOptions.prototype.maxResolution;
 
 
/**
 * Opacity. 0-1. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.layer.HeatmapOptions.prototype.opacity;
 
 
/**
 * Source.
 * @type {ol.source.Vector}
 * @api
 */
olx.layer.HeatmapOptions.prototype.source;
 
 
/**
 * Visibility. Default is `true` (visible).
 * @type {boolean|undefined}
 * @api
 */
olx.layer.HeatmapOptions.prototype.visible;
 
 
/**
 * @typedef {{opacity: (number|undefined),
 *     map: (ol.Map|undefined),
 *     source: (ol.source.Image|undefined),
 *     visible: (boolean|undefined),
 *     extent: (ol.Extent|undefined),
 *     minResolution: (number|undefined),
 *     maxResolution: (number|undefined)}}
 */
olx.layer.ImageOptions;
 
 
/**
 * Opacity (0, 1). Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.layer.ImageOptions.prototype.opacity;
 
 
/**
 * Source for this layer.
 * @type {ol.source.Image}
 * @api
 */
olx.layer.ImageOptions.prototype.source;
 
 
/**
 * Sets the layer as overlay on a map. The map will not manage this layer in its
 * layers collection, and the layer will be rendered on top. This is useful for
 * temporary layers. The standard way to add a layer to a map and have it
 * managed by the map is to use {@link ol.Map#addLayer}.
 * @type {ol.Map|undefined}
 * @api
 */
olx.layer.ImageOptions.prototype.map;
 
 
/**
 * Visibility. Default is `true` (visible).
 * @type {boolean|undefined}
 * @api
 */
olx.layer.ImageOptions.prototype.visible;
 
 
/**
 * The bounding extent for layer rendering.  The layer will not be rendered
 * outside of this extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.layer.ImageOptions.prototype.extent;
 
 
/**
 * The minimum resolution (inclusive) at which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.ImageOptions.prototype.minResolution;
 
 
/**
 * The maximum resolution (exclusive) below which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.ImageOptions.prototype.maxResolution;
 
 
/**
 * @typedef {{opacity: (number|undefined),
 *     preload: (number|undefined),
 *     source: (ol.source.Tile|undefined),
 *     map: (ol.Map|undefined),
 *     visible: (boolean|undefined),
 *     extent: (ol.Extent|undefined),
 *     minResolution: (number|undefined),
 *     maxResolution: (number|undefined),
 *     useInterimTilesOnError: (boolean|undefined)}}
 */
olx.layer.TileOptions;
 
 
/**
 * Opacity (0, 1). Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.layer.TileOptions.prototype.opacity;
 
 
/**
 * Preload. Load low-resolution tiles up to `preload` levels. By default
 * `preload` is `0`, which means no preloading.
 * @type {number|undefined}
 * @api
 */
olx.layer.TileOptions.prototype.preload;
 
 
/**
 * Source for this layer.
 * @type {ol.source.Tile}
 * @api
 */
olx.layer.TileOptions.prototype.source;
 
 
/**
 * Sets the layer as overlay on a map. The map will not manage this layer in its
 * layers collection, and the layer will be rendered on top. This is useful for
 * temporary layers. The standard way to add a layer to a map and have it
 * managed by the map is to use {@link ol.Map#addLayer}.
 * @type {ol.Map|undefined}
 * @api
 */
olx.layer.TileOptions.prototype.map;
 
 
/**
 * Visibility. Default is `true` (visible).
 * @type {boolean|undefined}
 * @api
 */
olx.layer.TileOptions.prototype.visible;
 
 
/**
 * The bounding extent for layer rendering.  The layer will not be rendered
 * outside of this extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.layer.TileOptions.prototype.extent;
 
 
/**
 * The minimum resolution (inclusive) at which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.TileOptions.prototype.minResolution;
 
 
/**
 * The maximum resolution (exclusive) below which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.TileOptions.prototype.maxResolution;
 
 
/**
 * Use interim tiles on error. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.layer.TileOptions.prototype.useInterimTilesOnError;
 
 
/**
 * @typedef {{renderOrder: (ol.RenderOrderFunction|null|undefined),
 *     minResolution: (number|undefined),
 *     maxResolution: (number|undefined),
 *     opacity: (number|undefined),
 *     renderBuffer: (number|undefined),
 *     source: (ol.source.Vector|undefined),
 *     map: (ol.Map|undefined),
 *     style: (ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined),
 *     updateWhileAnimating: (boolean|undefined),
 *     updateWhileInteracting: (boolean|undefined),
 *     visible: (boolean|undefined)}}
 */
olx.layer.VectorOptions;
 
 
/**
 * Render order. Function to be used when sorting features before rendering. By
 * default features are drawn in the order that they are created. Use `null` to
 * avoid the sort, but get an undefined draw order.
 * @type {ol.RenderOrderFunction|null|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.renderOrder;
 
 
/**
 * Sets the layer as overlay on a map. The map will not manage this layer in its
 * layers collection, and the layer will be rendered on top. This is useful for
 * temporary layers. The standard way to add a layer to a map and have it
 * managed by the map is to use {@link ol.Map#addLayer}.
 * @type {ol.Map|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.map;
 
 
/**
 * The bounding extent for layer rendering.  The layer will not be rendered
 * outside of this extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.extent;
 
 
/**
 * The minimum resolution (inclusive) at which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.minResolution;
 
 
/**
 * The maximum resolution (exclusive) below which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.maxResolution;
 
 
/**
 * Opacity. 0-1. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.opacity;
 
 
/**
 * The buffer around the viewport extent used by the renderer when getting
 * features from the vector source for the rendering or hit-detection.
 * Recommended value: the size of the largest symbol, line width or label.
 * Default is 100 pixels.
 * @type {number|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.renderBuffer;
 
 
/**
 * Source.
 * @type {ol.source.Vector}
 * @api
 */
olx.layer.VectorOptions.prototype.source;
 
 
/**
 * Layer style. See {@link ol.style} for default style which will be used if
 * this is not defined.
 * @type {ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.style;
 
 
/**
 * When set to `true`, feature batches will be recreated during animations.
 * This means that no vectors will be shown clipped, but the setting will have a
 * performance impact for large amounts of vector data. When set to `false`,
 * batches will be recreated when no animation is active.  Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.updateWhileAnimating;
 
 
/**
 * When set to `true`, feature batches will be recreated during interactions.
 * See also `updateWhileAnimating`. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.updateWhileInteracting;
 
 
/**
 * Visibility. Default is `true` (visible).
 * @type {boolean|undefined}
 * @api
 */
olx.layer.VectorOptions.prototype.visible;
 
 
/**
 * @typedef {{extent: (ol.Extent|undefined),
 *     map: (ol.Map|undefined),
 *     minResolution: (number|undefined),
 *     maxResolution: (number|undefined),
 *     opacity: (number|undefined),
 *     preload: (number|undefined),
 *     renderBuffer: (number|undefined),
 *     renderMode: (ol.layer.VectorTileRenderType|string|undefined),
 *     renderOrder: (ol.RenderOrderFunction|undefined),
 *     source: (ol.source.VectorTile|undefined),
 *     style: (ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined),
 *     updateWhileAnimating: (boolean|undefined),
 *     updateWhileInteracting: (boolean|undefined),
 *     visible: (boolean|undefined)}}
 */
olx.layer.VectorTileOptions;
 
 
/**
 * The buffer around the tile extent used by the renderer when getting features
 * from the vector tile for the rendering or hit-detection.
 * Recommended value: Vector tiles are usually generated with a buffer, so this
 * value should match the largest possible buffer of the used tiles. It should
 * be at least the size of the largest point symbol or line width.
 * Default is 100 pixels.
 * @type {number|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.renderBuffer;
 
 
/**
 * Render mode for vector tiles:
 *  * `'image'`: Vector tiles are rendered as images. Great performance, but
 *    point symbols and texts are always rotated with the view and pixels are
 *    scaled during zoom animations.
 *  * `'hybrid'`: Polygon and line elements are rendered as images, so pixels
 *    are scaled during zoom animations. Point symbols and texts are accurately
 *    rendered as vectors and can stay upright on rotated views.
 *  * `'vector'`: Vector tiles are rendered as vectors. Most accurate rendering
 *    even during animations, but slower performance than the other options.
 *
 * The default is `'hybrid'`.
 * @type {ol.layer.VectorTileRenderType|string|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.renderMode;
 
/**
 * Render order. Function to be used when sorting features before rendering. By
 * default features are drawn in the order that they are created.
 * @type {ol.RenderOrderFunction|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.renderOrder;
 
 
/**
 * Sets the layer as overlay on a map. The map will not manage this layer in its
 * layers collection, and the layer will be rendered on top. This is useful for
 * temporary layers. The standard way to add a layer to a map and have it
 * managed by the map is to use {@link ol.Map#addLayer}.
 * @type {ol.Map|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.map;
 
 
/**
 * The bounding extent for layer rendering.  The layer will not be rendered
 * outside of this extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.extent;
 
 
/**
 * The minimum resolution (inclusive) at which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.minResolution;
 
 
/**
 * The maximum resolution (exclusive) below which this layer will be visible.
 * @type {number|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.maxResolution;
 
 
/**
 * Opacity. 0-1. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.opacity;
 
 
/**
 * Preload. Load low-resolution tiles up to `preload` levels. By default
 * `preload` is `0`, which means no preloading.
 * @type {number|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.preload;
 
 
/**
 * Source.
 * @type {ol.source.VectorTile|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.source;
 
 
/**
 * Layer style. See {@link ol.style} for default style which will be used if
 * this is not defined.
 * @type {ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.style;
 
 
/**
 * When set to `true`, feature batches will be recreated during animations.
 * This means that no vectors will be shown clipped, but the setting will have a
 * performance impact for large amounts of vector data. When set to `false`,
 * batches will be recreated when no animation is active.  Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.updateWhileAnimating;
 
 
/**
 * When set to `true`, feature batches will be recreated during interactions.
 * See also `updateWhileAnimating`. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.updateWhileInteracting;
 
 
/**
 * Visibility. Default is `true` (visible).
 * @type {boolean|undefined}
 * @api
 */
olx.layer.VectorTileOptions.prototype.visible;
 
 
/**
 * Namespace.
 * @type {Object}
 */
olx.render;
 
 
/**
 * @typedef {{size: (ol.Size|undefined),
 *     pixelRatio: (number|undefined)}}
 */
olx.render.ToContextOptions;
 
 
/**
 * Desired size of the canvas in css pixels. When provided, both canvas and css
 * size will be set according to the `pixelRatio`. If not provided, the current
 * canvas and css sizes will not be altered.
 * @type {ol.Size|undefined}
 * @api
 */
olx.render.ToContextOptions.prototype.size;
 
 
/**
 * Pixel ratio (canvas pixel to css pixel ratio) for the canvas. Default
 * is the detected device pixel ratio.
 * @type {number|undefined}
 * @api
 */
olx.render.ToContextOptions.prototype.pixelRatio;
 
 
/**
 * Namespace.
 * @type {Object}
 */
olx.source;
 
 
/**
 * @typedef {{cacheSize: (number|undefined),
 *     culture: (string|undefined),
 *     hidpi: (boolean|undefined),
 *     key: string,
 *     imagerySet: string,
 *     maxZoom: (number|undefined),
 *     reprojectionErrorThreshold: (number|undefined),
 *     tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *     wrapX: (boolean|undefined)}}
 */
olx.source.BingMapsOptions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.BingMapsOptions.prototype.cacheSize;
 
 
/**
 * If `true` hidpi tiles will be requested. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.BingMapsOptions.prototype.hidpi;
 
 
/**
 * Culture code. Default is `en-us`.
 * @type {string|undefined}
 * @api
 */
olx.source.BingMapsOptions.prototype.culture;
 
 
/**
 * Bing Maps API key. Get yours at http://www.bingmapsportal.com/.
 * @type {string}
 * @api
 */
olx.source.BingMapsOptions.prototype.key;
 
 
/**
 * Type of imagery.
 * @type {string}
 * @api
 */
olx.source.BingMapsOptions.prototype.imagerySet;
 
 
/**
 * Max zoom. Default is what's advertized by the BingMaps service (`21`
 * currently).
 * @type {number|undefined}
 * @api
 */
olx.source.BingMapsOptions.prototype.maxZoom;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.BingMapsOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * Optional function to load a tile given a URL. The default is
 * ```js
 * function(imageTile, src) {
 *   imageTile.getImage().src = src;
 * };
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.BingMapsOptions.prototype.tileLoadFunction;
 
 
/**
 * Whether to wrap the world horizontally. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.BingMapsOptions.prototype.wrapX;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     distance: (number|undefined),
 *     extent: (ol.Extent|undefined),
 *     format: (ol.format.Feature|undefined),
 *     geometryFunction: (undefined|function(ol.Feature):ol.geom.Point),
 *     logo: (string|undefined),
 *     projection: ol.ProjectionLike,
 *     source: ol.source.Vector,
 *     wrapX: (boolean|undefined)}}
 */
olx.source.ClusterOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.ClusterOptions.prototype.attributions;
 
 
/**
 * Minimum distance in pixels between clusters. Default is `20`.
 * @type {number|undefined}
 * @api
 */
olx.source.ClusterOptions.prototype.distance;
 
 
/**
 * Extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.source.ClusterOptions.prototype.extent;
 
 
/**
 * Function that takes an {@link ol.Feature} as argument and returns an
 * {@link ol.geom.Point} as cluster calculation point for the feature. When a
 * feature should not be considered for clustering, the function should return
 * `null`. The default, which works when the underyling source contains point
 * features only, is
 * ```js
 * function(feature) {
 *   return feature.getGeometry();
 * }
 * ```
 * See {@link ol.geom.Polygon#getInteriorPoint} for a way to get a cluster
 * calculation point for polygons.
 * @type {undefined|function(ol.Feature):ol.geom.Point}
 * @api
 */
olx.source.ClusterOptions.prototype.geometryFunction;
 
 
/**
 * Format.
 * @type {ol.format.Feature|undefined}
 * @api
 */
olx.source.ClusterOptions.prototype.format;
 
 
/**
 * Logo.
 * @type {string|undefined}
 * @api
 */
olx.source.ClusterOptions.prototype.logo;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.ClusterOptions.prototype.projection;
 
 
/**
 * Source.
 * @type {ol.source.Vector}
 * @api
 */
olx.source.ClusterOptions.prototype.source;
 
 
/**
 * WrapX. Default is true
 * @type {boolean|undefined}
 * @api
 */
olx.source.ClusterOptions.prototype.wrapX;
 
 
/**
 * @typedef {{preemptive: (boolean|undefined),
 *     jsonp: (boolean|undefined),
 *     tileJSON: (TileJSON|undefined),
 *     url: (string|undefined)}}
 */
olx.source.TileUTFGridOptions;
 
 
/**
 * Use JSONP with callback to load the TileJSON. Useful when the server
 * does not support CORS. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.TileUTFGridOptions.prototype.jsonp;
 
 
/**
 * If `true` the TileUTFGrid source loads the tiles based on their "visibility".
 * This improves the speed of response, but increases traffic.
 * Note that if set to `false`, you need to pass `true` as `opt_request`
 * to the `forDataAtCoordinateAndResolution` method otherwise no data
 * will ever be loaded.
 * Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.TileUTFGridOptions.prototype.preemptive;
 
 
/**
 * TileJSON configuration for this source. If not provided, `url` must be
 * configured.
 * @type {TileJSON|undefined}
 * @api
 */
olx.source.TileUTFGridOptions.prototype.tileJSON;
 
 
/**
 * TileJSON endpoint that provides the configuration for this source. Request
 * will be made through JSONP. If not provided, `tileJSON` must be configured.
 * @type {string|undefined}
 * @api
 */
olx.source.TileUTFGridOptions.prototype.url;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *            cacheSize: (number|undefined),
 *            crossOrigin: (null|string|undefined),
 *            logo: (string|olx.LogoOptions|undefined),
 *            opaque: (boolean|undefined),
 *            projection: ol.ProjectionLike,
 *            reprojectionErrorThreshold: (number|undefined),
 *            state: (ol.source.State|undefined),
 *            tileClass: (function(new: ol.ImageTile, ol.TileCoord,
 *                                 ol.TileState, string, ?string,
 *                                 ol.TileLoadFunctionType)|undefined),
 *            tileGrid: (ol.tilegrid.TileGrid|undefined),
 *            tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *            tilePixelRatio: (number|undefined),
 *            tileUrlFunction: (ol.TileUrlFunctionType|undefined),
 *            url: (string|undefined),
 *            urls: (Array.<string>|undefined),
 *            wrapX: (boolean|undefined)}}
 */
olx.source.TileImageOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.attributions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.cacheSize;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.crossOrigin;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.logo;
 
 
/**
 * Whether the layer is opaque.
 * @type {boolean|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.opaque;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.TileImageOptions.prototype.projection;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * Source state.
 * @type {ol.source.State|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.state;
 
 
/**
 * Class used to instantiate image tiles. Default is {@link ol.ImageTile}.
 * @type {function(new: ol.ImageTile, ol.TileCoord,
 *                 ol.TileState, string, ?string,
 *                 ol.TileLoadFunctionType)|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.tileClass;
 
 
/**
 * Tile grid.
 * @type {ol.tilegrid.TileGrid|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.tileGrid;
 
 
/**
 * Optional function to load a tile given a URL. The default is
 * ```js
 * function(imageTile, src) {
 *   imageTile.getImage().src = src;
 * };
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.tileLoadFunction;
 
 
/**
 * The pixel ratio used by the tile service. For example, if the tile
 * service advertizes 256px by 256px tiles but actually sends 512px
 * by 512px images (for retina/hidpi devices) then `tilePixelRatio`
 * should be set to `2`. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.tilePixelRatio;
 
 
/**
 * Optional function to get tile URL given a tile coordinate and the projection.
 * @type {ol.TileUrlFunctionType|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.tileUrlFunction;
 
 
/**
 * URL template. Must include `{x}`, `{y}` or `{-y}`, and `{z}` placeholders.
 * A `{?-?}` template pattern, for example `subdomain{a-f}.domain.com`, may be
 * used instead of defining each one separately in the `urls` option.
 * @type {string|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.url;
 
 
/**
 * An array of URL templates.
 * @type {Array.<string>|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.urls;
 
 
/**
 * Whether to wrap the world horizontally. The default, `undefined`, is to
 * request out-of-bounds tiles from the server. When set to `false`, only one
 * world will be rendered. When set to `true`, tiles will be requested for one
 * world only, but they will be wrapped horizontally to render multiple worlds.
 * @type {boolean|undefined}
 * @api
 */
olx.source.TileImageOptions.prototype.wrapX;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *            cacheSize: (number|undefined),
 *            format: (ol.format.Feature|undefined),
 *            logo: (string|olx.LogoOptions|undefined),
 *            overlaps: (boolean|undefined),
 *            projection: ol.ProjectionLike,
 *            state: (ol.source.State|undefined),
 *            tileClass: (function(new: ol.VectorTile, ol.TileCoord,
 *                 ol.TileState, string, ol.format.Feature,
 *                 ol.TileLoadFunctionType)|undefined),
 *            tileGrid: (ol.tilegrid.TileGrid|undefined),
 *            tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *            tilePixelRatio: (number|undefined),
 *            tileUrlFunction: (ol.TileUrlFunctionType|undefined),
 *            url: (string|undefined),
 *            urls: (Array.<string>|undefined),
 *            wrapX: (boolean|undefined)}}
 */
olx.source.VectorTileOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.attributions;
 
 
/**
 * Cache size. Default is `128`.
 * @type {number|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.cacheSize;
 
 
/**
 * Feature format for tiles. Used and required by the default
 * `tileLoadFunction`.
 * @type {ol.format.Feature|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.format;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.logo;
 
 
/**
 * This source may have overlapping geometries. Default is `true`. Setting this
 * to `false` (e.g. for sources with polygons that represent administrative
 * boundaries or TopoJSON sources) allows the renderer to optimise fill and
 * stroke operations.
 * @type {boolean|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.overlaps;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.VectorTileOptions.prototype.projection;
 
 
/**
 * Source state.
 * @type {ol.source.State|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.state;
 
 
/**
 * Class used to instantiate image tiles. Default is {@link ol.VectorTile}.
 * @type {function(new: ol.VectorTile, ol.TileCoord,
 *                 ol.TileState, string, ol.format.Feature,
 *                 ol.TileLoadFunctionType)|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.tileClass;
 
 
/**
 * Tile grid.
 * @type {ol.tilegrid.TileGrid|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.tileGrid;
 
 
/**
 * Optional function to load a tile given a URL. Could look like this:
 * ```js
 * function(tile, url) {
 *   tile.setLoader(function() {
 *     var data = // ... fetch data
 *     var format = tile.getFormat();
 *     tile.setFeatures(format.readFeatures(data));
 *     tile.setProjection(format.readProjection(data));
 *   };
 * });
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.tileLoadFunction;
 
 
/**
 * The pixel ratio used by the tile service. For example, if the tile
 * service advertizes 256px by 256px tiles but actually sends 512px
 * by 512px tiles (for retina/hidpi devices) then `tilePixelRatio`
 * should be set to `2`. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.tilePixelRatio;
 
 
/**
 * Optional function to get tile URL given a tile coordinate and the projection.
 * @type {ol.TileUrlFunctionType|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.tileUrlFunction;
 
 
/**
 * URL template. Must include `{x}`, `{y}` or `{-y}`, and `{z}` placeholders.
 * A `{?-?}` template pattern, for example `subdomain{a-f}.domain.com`, may be
 * used instead of defining each one separately in the `urls` option.
 * @type {string|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.url;
 
 
/**
 * An array of URL templates.
 * @type {Array.<string>|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.urls;
 
 
/**
 * Whether to wrap the world horizontally. When set to `false`, only one world
 * will be rendered. When set to `true`, tiles will be wrapped horizontally to
 * render multiple worlds. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.VectorTileOptions.prototype.wrapX;
 
 
/**
 * @typedef {{url: (string|undefined),
 *     displayDpi: (number|undefined),
 *     metersPerUnit: (number|undefined),
 *     hidpi: (boolean|undefined),
 *     useOverlay: (boolean|undefined),
 *     projection: ol.ProjectionLike,
 *     ratio: (number|undefined),
 *     resolutions: (Array.<number>|undefined),
 *     imageLoadFunction: (ol.ImageLoadFunctionType|undefined),
 *     params: (Object|undefined)}}
 */
olx.source.ImageMapGuideOptions;
 
 
/**
 * The mapagent url.
 * @type {string|undefined}
 * @api
 */
olx.source.ImageMapGuideOptions.prototype.url;
 
 
/**
 * The display resolution. Default is `96`.
 * @type {number|undefined}
 * @api
 */
olx.source.ImageMapGuideOptions.prototype.displayDpi;
 
 
/**
 * The meters-per-unit value. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.source.ImageMapGuideOptions.prototype.metersPerUnit;
 
 
/**
 * Use the `ol.Map#pixelRatio` value when requesting the image from the remote
 * server. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.ImageMapGuideOptions.prototype.hidpi;
 
 
/**
 * If `true`, will use `GETDYNAMICMAPOVERLAYIMAGE`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.ImageMapGuideOptions.prototype.useOverlay;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.ImageMapGuideOptions.prototype.projection;
 
 
/**
 * Ratio. `1` means image requests are the size of the map viewport, `2` means
 * twice the width and height of the map viewport, and so on. Must be `1` or
 * higher. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.source.ImageMapGuideOptions.prototype.ratio;
 
 
/**
 * Resolutions. If specified, requests will be made for these resolutions only.
 * @type {Array.<number>|undefined}
 * @api
 */
olx.source.ImageMapGuideOptions.prototype.resolutions;
 
 
/**
 * Optional function to load an image given a URL.
 * @type {ol.ImageLoadFunctionType|undefined}
 * @api
 */
olx.source.ImageMapGuideOptions.prototype.imageLoadFunction;
 
 
/**
 * Additional parameters.
 * @type {Object|undefined}
 * @api
 */
olx.source.ImageMapGuideOptions.prototype.params;
 
 
/**
 * @typedef {{cacheSize: (number|undefined),
 *     layer: string,
 *     reprojectionErrorThreshold: (number|undefined),
 *     tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *     url: (string|undefined)}}
 */
olx.source.MapQuestOptions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.MapQuestOptions.prototype.cacheSize;
 
 
/**
 * Layer. Possible values are `osm`, `sat`, and `hyb`.
 * @type {string}
 * @api
 */
olx.source.MapQuestOptions.prototype.layer;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.MapQuestOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * Optional function to load a tile given a URL. The default is
 * ```js
 * function(imageTile, src) {
 *   imageTile.getImage().src = src;
 * };
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.MapQuestOptions.prototype.tileLoadFunction;
 
 
/**
 * URL template. Must include `{x}`, `{y}` or `{-y}`, and `{z}` placeholders.
 * @type {string|undefined}
 * @api
 */
olx.source.MapQuestOptions.prototype.url;
 
 
/**
 * @typedef {{projection: ol.ProjectionLike,
 *     tileGrid: (ol.tilegrid.TileGrid|undefined),
 *     wrapX: (boolean|undefined)}}
 */
olx.source.TileDebugOptions;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.TileDebugOptions.prototype.projection;
 
 
/**
 * Tile grid.
 * @type {ol.tilegrid.TileGrid|undefined}
 * @api
 */
olx.source.TileDebugOptions.prototype.tileGrid;
 
 
/**
 * Whether to wrap the world horizontally. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.TileDebugOptions.prototype.wrapX;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     cacheSize: (number|undefined),
 *     crossOrigin: (null|string|undefined),
 *     maxZoom: (number|undefined),
 *     opaque: (boolean|undefined),
 *     reprojectionErrorThreshold: (number|undefined),
 *     tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *     url: (string|undefined),
 *     wrapX: (boolean|undefined)}}
 */
olx.source.OSMOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.OSMOptions.prototype.attributions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.OSMOptions.prototype.cacheSize;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 *
 * Default is `anonymous`.
 * @type {null|string|undefined}
 * @api
 */
olx.source.OSMOptions.prototype.crossOrigin;
 
 
/**
 * Max zoom. Default is `19`.
 * @type {number|undefined}
 * @api
 */
olx.source.OSMOptions.prototype.maxZoom;
 
 
/**
 * Whether the layer is opaque. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.OSMOptions.prototype.opaque;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.OSMOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * Optional function to load a tile given a URL. The default is
 * ```js
 * function(imageTile, src) {
 *   imageTile.getImage().src = src;
 * };
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.OSMOptions.prototype.tileLoadFunction;
 
 
/**
 * URL template. Must include `{x}`, `{y}` or `{-y}`, and `{z}` placeholders.
 * Default is `https://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png`.
 * @type {string|undefined}
 * @api
 */
olx.source.OSMOptions.prototype.url;
 
 
/**
 * Whether to wrap the world horizontally. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.OSMOptions.prototype.wrapX;
 
 
/**
 * @typedef {{attributions: (Array.<ol.Attribution>|undefined),
 *     crossOrigin: (null|string|undefined),
 *     hidpi: (boolean|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     imageLoadFunction: (ol.ImageLoadFunctionType|undefined),
 *     params: Object.<string,*>,
 *     projection: ol.ProjectionLike,
 *     ratio: (number|undefined),
 *     resolutions: (Array.<number>|undefined),
 *     url: (string|undefined)}}
 */
olx.source.ImageArcGISRestOptions;
 
 
/**
 * Attributions.
 * @type {Array.<ol.Attribution>|undefined}
 * @api
 */
olx.source.ImageArcGISRestOptions.prototype.attributions;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.source.ImageArcGISRestOptions.prototype.crossOrigin;
 
 
/**
 * Use the `ol.Map#pixelRatio` value when requesting the image from the remote
 * server. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.ImageArcGISRestOptions.prototype.hidpi;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.ImageArcGISRestOptions.prototype.logo;
 
 
/**
 * Optional function to load an image given a URL.
 * @type {ol.ImageLoadFunctionType|undefined}
 * @api
 */
olx.source.ImageArcGISRestOptions.prototype.imageLoadFunction;
 
 
/**
 * ArcGIS Rest parameters. This field is optional. Service defaults will be
 * used for any fields not specified. `FORMAT` is `PNG32` by default. `F` is `IMAGE` by
 * default. `TRANSPARENT` is `true` by default.  `BBOX, `SIZE`, `BBOXSR`,
 * and `IMAGESR` will be set dynamically. Set `LAYERS` to
 * override the default service layer visibility. See
 * {@link http://resources.arcgis.com/en/help/arcgis-rest-api/index.html#/Export_Map/02r3000000v7000000/}
 * for further reference.
 * @type {Object.<string,*>|undefined}
 * @api
 */
olx.source.ImageArcGISRestOptions.prototype.params;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.ImageArcGISRestOptions.prototype.projection;
 
 
/**
 * Ratio. `1` means image requests are the size of the map viewport, `2` means
 * twice the size of the map viewport, and so on. Default is `1.5`.
 * @type {number|undefined}
 * @api
 */
olx.source.ImageArcGISRestOptions.prototype.ratio;
 
 
/**
 * Resolutions. If specified, requests will be made for these resolutions only.
 * @type {Array.<number>|undefined}
 * @api
 */
olx.source.ImageArcGISRestOptions.prototype.resolutions;
 
 
/**
 * ArcGIS Rest service URL for a Map Service or Image Service. The
 * url should include /MapServer or /ImageServer.
 * @type {string|undefined}
 * @api
 */
olx.source.ImageArcGISRestOptions.prototype.url;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     canvasFunction: ol.CanvasFunctionType,
 *     logo: (string|olx.LogoOptions|undefined),
 *     projection: ol.ProjectionLike,
 *     ratio: (number|undefined),
 *     resolutions: (Array.<number>|undefined),
 *     state: (ol.source.State|undefined)}}
 */
olx.source.ImageCanvasOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.ImageCanvasOptions.prototype.attributions;
 
 
/**
 * Canvas function. The function returning the canvas element used by the source
 * as an image. The arguments passed to the function are: `{ol.Extent}` the
 * image extent, `{number}` the image resolution, `{number}` the device pixel
 * ratio, `{ol.Size}` the image size, and `{ol.proj.Projection}` the image
 * projection. The canvas returned by this function is cached by the source. If
 * the value returned by the function is later changed then
 * `dispatchChangeEvent` should be called on the source for the source to
 * invalidate the current cached image.
 * @type {ol.CanvasFunctionType}
 * @api
 */
olx.source.ImageCanvasOptions.prototype.canvasFunction;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.ImageCanvasOptions.prototype.logo;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.ImageCanvasOptions.prototype.projection;
 
 
/**
 * Ratio. 1 means canvases are the size of the map viewport, 2 means twice the
 * width and height of the map viewport, and so on. Must be `1` or higher.
 * Default is `1.5`.
 * @type {number|undefined}
 * @api
 */
olx.source.ImageCanvasOptions.prototype.ratio;
 
 
/**
 * Resolutions. If specified, new canvases will be created for these resolutions
 * only.
 * @type {Array.<number>|undefined}
 * @api
 */
olx.source.ImageCanvasOptions.prototype.resolutions;
 
 
/**
 * Source state.
 * @type {ol.source.State|undefined}
 * @api
 */
olx.source.ImageCanvasOptions.prototype.state;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     projection: ol.ProjectionLike,
 *     ratio: (number|undefined),
 *     renderBuffer: (number|undefined),
 *     resolutions: (Array.<number>|undefined),
 *     source: ol.source.Vector,
 *     style: (ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined)}}
 */
olx.source.ImageVectorOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.ImageVectorOptions.prototype.attributions;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.ImageVectorOptions.prototype.logo;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.ImageVectorOptions.prototype.projection;
 
 
/**
 * Ratio. 1 means canvases are the size of the map viewport, 2 means twice the
 * width and height of the map viewport, and so on. Must be `1` or higher.
 * Default is `1.5`.
 * @type {number|undefined}
 * @api
 */
olx.source.ImageVectorOptions.prototype.ratio;
 
 
/**
 * The buffer around the viewport extent used by the renderer when getting
 * features from the vector source for the rendering or hit-detection.
 * Recommended value: the size of the largest symbol, line width or label.
 * Default is 100 pixels.
 * @type {number|undefined}
 * @api
 */
olx.source.ImageVectorOptions.prototype.renderBuffer;
 
 
/**
 * Resolutions. If specified, new canvases will be created for these resolutions
 * only.
 * @type {Array.<number>|undefined}
 * @api
 */
olx.source.ImageVectorOptions.prototype.resolutions;
 
 
/**
 * The vector source from which the vector features drawn in canvas elements are
 * read.
 * @type {ol.source.Vector}
 * @api
 */
olx.source.ImageVectorOptions.prototype.source;
 
 
/**
 * Style to use when rendering features to the canvas.
 * @type {ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined}
 * @api
 */
olx.source.ImageVectorOptions.prototype.style;
 
 
/**
 * @typedef {{sources: Array.<ol.source.Source>,
 *     operation: (ol.RasterOperation|undefined),
 *     lib: (Object|undefined),
 *     threads: (number|undefined),
 *     operationType: (ol.source.RasterOperationType|undefined)}}
 * @api
 */
olx.source.RasterOptions;
 
 
/**
 * Input sources.
 * @type {Array.<ol.source.Source>}
 * @api
 */
olx.source.RasterOptions.prototype.sources;
 
 
/**
 * Raster operation.  The operation will be called with data from input sources
 * and the output will be assigned to the raster source.
 * @type {ol.RasterOperation|undefined}
 * @api
 */
olx.source.RasterOptions.prototype.operation;
 
 
/**
 * Functions that will be made available to operations run in a worker.
 * @type {Object|undefined}
 * @api
 */
olx.source.RasterOptions.prototype.lib;
 
 
/**
 * By default, operations will be run in a single worker thread.  To avoid using
 * workers altogether, set `threads: 0`.  For pixel operations, operations can
 * be run in multiple worker threads.  Note that there is additional overhead in
 * transferring data to multiple workers, and that depending on the user's
 * system, it may not be possible to parallelize the work.
 * @type {number|undefined}
 * @api
 */
olx.source.RasterOptions.prototype.threads;
 
 
/**
 * Operation type.  Supported values are `'pixel'` and `'image'`.  By default,
 * `'pixel'` operations are assumed, and operations will be called with an
 * array of pixels from input sources.  If set to `'image'`, operations will
 * be called with an array of ImageData objects from input sources.
 * @type {ol.source.RasterOperationType|undefined}
 * @api
 */
olx.source.RasterOptions.prototype.operationType;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     crossOrigin: (null|string|undefined),
 *     hidpi: (boolean|undefined),
 *     serverType: (ol.source.WMSServerType|string|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     imageLoadFunction: (ol.ImageLoadFunctionType|undefined),
 *     params: Object.<string,*>,
 *     projection: ol.ProjectionLike,
 *     ratio: (number|undefined),
 *     resolutions: (Array.<number>|undefined),
 *     url: (string|undefined)}}
 */
olx.source.ImageWMSOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.ImageWMSOptions.prototype.attributions;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.source.ImageWMSOptions.prototype.crossOrigin;
 
 
/**
 * Use the `ol.Map#pixelRatio` value when requesting the image from the remote
 * server. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.ImageWMSOptions.prototype.hidpi;
 
 
/**
 * The type of the remote WMS server: `mapserver`, `geoserver` or `qgis`. Only
 * needed if `hidpi` is `true`. Default is `undefined`.
 * @type {ol.source.WMSServerType|string|undefined}
 * @api
 */
olx.source.ImageWMSOptions.prototype.serverType;
 
 
/**
 * Optional function to load an image given a URL.
 * @type {ol.ImageLoadFunctionType|undefined}
 * @api
 */
olx.source.ImageWMSOptions.prototype.imageLoadFunction;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.ImageWMSOptions.prototype.logo;
 
 
/**
 * WMS request parameters. At least a `LAYERS` param is required. `STYLES` is
 * `''` by default. `VERSION` is `1.3.0` by default. `WIDTH`, `HEIGHT`, `BBOX`
 * and `CRS` (`SRS` for WMS version < 1.3.0) will be set dynamically.
 * @type {Object.<string,*>}
 * @api
 */
olx.source.ImageWMSOptions.prototype.params;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.ImageWMSOptions.prototype.projection;
 
 
/**
 * Ratio. `1` means image requests are the size of the map viewport, `2` means
 * twice the width and height of the map viewport, and so on. Must be `1` or
 * higher. Default is `1.5`.
 * @type {number|undefined}
 * @api
 */
olx.source.ImageWMSOptions.prototype.ratio;
 
 
/**
 * Resolutions. If specified, requests will be made for these resolutions only.
 * @type {Array.<number>|undefined}
 * @api
 */
olx.source.ImageWMSOptions.prototype.resolutions;
 
 
/**
 * WMS service URL.
 * @type {string|undefined}
 * @api
 */
olx.source.ImageWMSOptions.prototype.url;
 
 
/**
 * @typedef {{cacheSize: (number|undefined),
 *     layer: string,
 *     minZoom: (number|undefined),
 *     maxZoom: (number|undefined),
 *     opaque: (boolean|undefined),
 *     reprojectionErrorThreshold: (number|undefined),
 *     tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *     url: (string|undefined)}}
 */
olx.source.StamenOptions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.StamenOptions.prototype.cacheSize;
 
/**
 * Layer.
 * @type {string}
 * @api
 */
olx.source.StamenOptions.prototype.layer;
 
 
/**
 * Minimum zoom.
 * @type {number|undefined}
 * @api
 */
olx.source.StamenOptions.prototype.minZoom;
 
 
/**
 * Maximum zoom.
 * @type {number|undefined}
 * @api
 */
olx.source.StamenOptions.prototype.maxZoom;
 
 
/**
 * Whether the layer is opaque.
 * @type {boolean|undefined}
 * @api
 */
olx.source.StamenOptions.prototype.opaque;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.StamenOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * Optional function to load a tile given a URL. The default is
 * ```js
 * function(imageTile, src) {
 *   imageTile.getImage().src = src;
 * };
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.StamenOptions.prototype.tileLoadFunction;
 
 
/**
 * URL template. Must include `{x}`, `{y}` or `{-y}`, and `{z}` placeholders.
 * @type {string|undefined}
 * @api
 */
olx.source.StamenOptions.prototype.url;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     crossOrigin: (null|string|undefined),
 *     imageExtent: (ol.Extent),
 *     imageLoadFunction: (ol.ImageLoadFunctionType|undefined),
 *     imageSize: (ol.Size|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     projection: ol.ProjectionLike,
 *     url: string}}
 */
olx.source.ImageStaticOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.ImageStaticOptions.prototype.attributions;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.source.ImageStaticOptions.prototype.crossOrigin;
 
 
/**
 * Extent of the image in map coordinates.  This is the [left, bottom, right,
 * top] map coordinates of your image.
 * @type {ol.Extent}
 * @api
 */
olx.source.ImageStaticOptions.prototype.imageExtent;
 
 
/**
 * Optional function to load an image given a URL.
 * @type {ol.ImageLoadFunctionType|undefined}
 * @api
 */
olx.source.ImageStaticOptions.prototype.imageLoadFunction;
 
 
/**
 * Optional logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.ImageStaticOptions.prototype.logo;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.ImageStaticOptions.prototype.projection;
 
 
/**
 * Size of the image in pixels. Usually the image size is auto-detected, so this
 * only needs to be set if auto-detection fails for some reason.
 * @type {ol.Size|undefined}
 * @api
 */
olx.source.ImageStaticOptions.prototype.imageSize;
 
 
/**
 * Image URL.
 * @type {string}
 * @api
 */
olx.source.ImageStaticOptions.prototype.url;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     cacheSize: (number|undefined),
 *     crossOrigin: (null|string|undefined),
 *     params: (Object.<string, *>|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     tileGrid: (ol.tilegrid.TileGrid|undefined),
 *     projection: ol.ProjectionLike,
 *     reprojectionErrorThreshold: (number|undefined),
 *     tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *     url: (string|undefined),
 *     urls: (Array.<string>|undefined),
 *     wrapX: (boolean|undefined)}}
 */
olx.source.TileArcGISRestOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.attributions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.cacheSize;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.crossOrigin;
 
 
/**
 * ArcGIS Rest parameters. This field is optional. Service defaults will be
 * used for any fields not specified. `FORMAT` is `PNG32` by default. `F` is `IMAGE` by
 * default. `TRANSPARENT` is `true` by default.  `BBOX, `SIZE`, `BBOXSR`,
 * and `IMAGESR` will be set dynamically. Set `LAYERS` to
 * override the default service layer visibility. See
 * {@link http://resources.arcgis.com/en/help/arcgis-rest-api/index.html#/Export_Map/02r3000000v7000000/}
 * for further reference.
 * @type {Object.<string,*>|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.params;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.logo;
 
 
/**
 * Tile grid. Base this on the resolutions, tilesize and extent supported by the
 * server.
 * If this is not defined, a default grid will be used: if there is a projection
 * extent, the grid will be based on that; if not, a grid based on a global
 * extent with origin at 0,0 will be used.
 * @type {ol.tilegrid.TileGrid|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.tileGrid;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.projection;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * Optional function to load a tile given a URL. The default is
 * ```js
 * function(imageTile, src) {
 *   imageTile.getImage().src = src;
 * };
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.tileLoadFunction;
 
 
/**
 * ArcGIS Rest service URL for a Map Service or Image Service. The
 * url should include /MapServer or /ImageServer.
 * @type {string|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.url;
 
 
/**
 * Whether to wrap the world horizontally. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.wrapX;
 
 
/**
 * ArcGIS Rest service urls. Use this instead of `url` when the ArcGIS Service supports multiple
 * urls for export requests.
 * @type {Array.<string>|undefined}
 * @api
 */
olx.source.TileArcGISRestOptions.prototype.urls;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     cacheSize: (number|undefined),
 *     crossOrigin: (null|string|undefined),
 *     jsonp: (boolean|undefined),
 *     reprojectionErrorThreshold: (number|undefined),
 *     tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *     url: string,
 *     wrapX: (boolean|undefined)}}
 */
olx.source.TileJSONOptions;
 
 
/**
 * Optional attributions for the source.  If provided, these will be used
 * instead of any attribution data advertised by the server.  If not provided,
 * any attributions advertised by the server will be used.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.TileJSONOptions.prototype.attributions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.TileJSONOptions.prototype.cacheSize;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.source.TileJSONOptions.prototype.crossOrigin;
 
 
/**
 * Use JSONP with callback to load the TileJSON. Useful when the server
 * does not support CORS. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.TileJSONOptions.prototype.jsonp;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.TileJSONOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * Optional function to load a tile given a URL. The default is
 * ```js
 * function(imageTile, src) {
 *   imageTile.getImage().src = src;
 * };
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.TileJSONOptions.prototype.tileLoadFunction;
 
 
/**
 * URL to the TileJSON file.
 * @type {string}
 * @api
 */
olx.source.TileJSONOptions.prototype.url;
 
 
/**
 * Whether to wrap the world horizontally. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.TileJSONOptions.prototype.wrapX;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     cacheSize: (number|undefined),
 *     params: Object.<string,*>,
 *     crossOrigin: (null|string|undefined),
 *     gutter: (number|undefined),
 *     hidpi: (boolean|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     tileGrid: (ol.tilegrid.TileGrid|undefined),
 *     projection: ol.ProjectionLike,
 *     reprojectionErrorThreshold: (number|undefined),
 *     serverType: (ol.source.WMSServerType|string|undefined),
 *     tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *     url: (string|undefined),
 *     urls: (Array.<string>|undefined),
 *     wrapX: (boolean|undefined)}}
 */
olx.source.TileWMSOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.attributions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.cacheSize;
 
 
/**
 * WMS request parameters. At least a `LAYERS` param is required. `STYLES` is
 * `''` by default. `VERSION` is `1.3.0` by default. `WIDTH`, `HEIGHT`, `BBOX`
 * and `CRS` (`SRS` for WMS version < 1.3.0) will be set dynamically.
 * @type {Object.<string,*>}
 * @api
 */
olx.source.TileWMSOptions.prototype.params;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.crossOrigin;
 
 
/**
 * The size in pixels of the gutter around image tiles to ignore. By setting
 * this property to a non-zero value, images will be requested that are wider
 * and taller than the tile size by a value of `2 x gutter`. Defaults to zero.
 * Using a non-zero value allows artifacts of rendering at tile edges to be
 * ignored. If you control the WMS service it is recommended to address
 * "artifacts at tile edges" issues by properly configuring the WMS service. For
 * example, MapServer has a `tile_map_edge_buffer` configuration parameter for
 * this. See http://mapserver.org/output/tile_mode.html.
 * @type {number|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.gutter;
 
 
/**
 * Use the `ol.Map#pixelRatio` value when requesting the image from the remote
 * server. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.hidpi;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.logo;
 
 
/**
 * Tile grid. Base this on the resolutions, tilesize and extent supported by the
 * server.
 * If this is not defined, a default grid will be used: if there is a projection
 * extent, the grid will be based on that; if not, a grid based on a global
 * extent with origin at 0,0 will be used.
 * @type {ol.tilegrid.TileGrid|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.tileGrid;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.TileWMSOptions.prototype.projection;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * The type of the remote WMS server. Currently only used when `hidpi` is
 * `true`. Default is `undefined`.
 * @type {ol.source.WMSServerType|string|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.serverType;
 
 
/**
 * Optional function to load a tile given a URL. The default is
 * ```js
 * function(imageTile, src) {
 *   imageTile.getImage().src = src;
 * };
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.tileLoadFunction;
 
 
/**
 * WMS service URL.
 * @type {string|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.url;
 
 
/**
 * WMS service urls. Use this instead of `url` when the WMS supports multiple
 * urls for GetMap requests.
 * @type {Array.<string>|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.urls;
 
 
/**
 * Whether to wrap the world horizontally. When set to `false`, only one world
 * will be rendered. When `true`, tiles will be requested for one world only,
 * but they will be wrapped horizontally to render multiple worlds. The default
 * is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.TileWMSOptions.prototype.wrapX;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     features: (Array.<ol.Feature>|ol.Collection.<ol.Feature>|undefined),
 *     format: (ol.format.Feature|undefined),
 *     loader: (ol.FeatureLoader|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     overlaps: (boolean|undefined),
 *     strategy: (ol.LoadingStrategy|undefined),
 *     url: (string|ol.FeatureUrlFunction|undefined),
 *     useSpatialIndex: (boolean|undefined),
 *     wrapX: (boolean|undefined)}}
 */
olx.source.VectorOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.VectorOptions.prototype.attributions;
 
 
/**
 * Features. If provided as {@link ol.Collection}, the features in the source
 * and the collection will stay in sync.
 * @type {Array.<ol.Feature>|ol.Collection.<ol.Feature>|undefined}
 * @api
 */
olx.source.VectorOptions.prototype.features;
 
 
/**
 * The feature format used by the XHR feature loader when `url` is set.
 * Required if `url` is set, otherwise ignored. Default is `undefined`.
 * @type {ol.format.Feature|undefined}
 * @api
 */
olx.source.VectorOptions.prototype.format;
 
 
/**
 * The loader function used to load features, from a remote source for example.
 * If this is not set and `url` is set, the source will create and use an XHR
 * feature loader.
 * @type {ol.FeatureLoader|undefined}
 * @api
 */
olx.source.VectorOptions.prototype.loader;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.VectorOptions.prototype.logo;
 
 
/**
 * This source may have overlapping geometries. Default is `true`. Setting this
 * to `false` (e.g. for sources with polygons that represent administrative
 * boundaries or TopoJSON sources) allows the renderer to optimise fill and
 * stroke operations.
 * @type {boolean|undefined}
 * @api
 */
olx.source.VectorOptions.prototype.overlaps;
 
 
/**
 * The loading strategy to use. By default an {@link ol.loadingstrategy.all}
 * strategy is used, a one-off strategy which loads all features at once.
 * @type {ol.LoadingStrategy|undefined}
 * @api
 */
olx.source.VectorOptions.prototype.strategy;
 
 
/**
 * Setting this option instructs the source to load features using an XHR loader
 * (see {@link ol.featureloader.xhr}). Use a `string` and an
 * {@link ol.loadingstrategy.all} for a one-off download of all features from
 * the given URL. Use a {@link ol.FeatureUrlFunction} to generate the url with
 * other loading strategies.
 * Requires `format` to be set as well.
 * When default XHR feature loader is provided, the features will
 * be transformed from the data projection to the view projection
 * during parsing. If your remote data source does not advertise its projection
 * properly, this transformation will be incorrect. For some formats, the
 * default projection (usually EPSG:4326) can be overridden by setting the
 * defaultDataProjection constructor option on the format.
 * Note that if a source contains non-feature data, such as a GeoJSON geometry
 * or a KML NetworkLink, these will be ignored. Use a custom loader to load these.
 * @type {string|ol.FeatureUrlFunction|undefined}
 * @api
 */
olx.source.VectorOptions.prototype.url;
 
 
/**
 * By default, an RTree is used as spatial index. When features are removed and
 * added frequently, and the total number of features is low, setting this to
 * `false` may improve performance.
 *
 * Note that
 * {@link ol.source.Vector#getFeaturesInExtent},
 * {@link ol.source.Vector#getClosestFeatureToCoordinate} and
 * {@link ol.source.Vector#getExtent} cannot be used when `useSpatialIndex` is
 * set to `false`, and {@link ol.source.Vector#forEachFeatureInExtent} will loop
 * through all features.
 *
 * When set to `false`, the features will be maintained in an
 * {@link ol.Collection}, which can be retrieved through
 * {@link ol.source.Vector#getFeaturesCollection}.
 *
 * The default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.VectorOptions.prototype.useSpatialIndex;
 
 
/**
 * Wrap the world horizontally. Default is `true`. For vector editing across the
 * -180° and 180° meridians to work properly, this should be set to `false`. The
 * resulting geometry coordinates will then exceed the world bounds.
 * @type {boolean|undefined}
 * @api
 */
olx.source.VectorOptions.prototype.wrapX;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     cacheSize: (number|undefined),
 *     crossOrigin: (string|null|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     tileGrid: ol.tilegrid.WMTS,
 *     projection: ol.ProjectionLike,
 *     reprojectionErrorThreshold: (number|undefined),
 *     requestEncoding: (ol.source.WMTSRequestEncoding|string|undefined),
 *     layer: string,
 *     style: string,
 *     tilePixelRatio: (number|undefined),
 *     version: (string|undefined),
 *     format: (string|undefined),
 *     matrixSet: string,
 *     dimensions: (!Object|undefined),
 *     url: (string|undefined),
 *     tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *     urls: (Array.<string>|undefined),
 *     tileClass: (function(new: ol.ImageTile, ol.TileCoord,
 *                          ol.TileState, string, ?string,
 *                          ol.TileLoadFunctionType)|undefined),
 *     wrapX: (boolean|undefined)}}
 */
olx.source.WMTSOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.attributions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.cacheSize;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {string|null|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.crossOrigin;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.logo;
 
 
/**
 * Tile grid.
 * @type {ol.tilegrid.WMTS}
 * @api
 */
olx.source.WMTSOptions.prototype.tileGrid;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.WMTSOptions.prototype.projection;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * Request encoding. Default is `KVP`.
 * @type {ol.source.WMTSRequestEncoding|string|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.requestEncoding;
 
 
/**
 * Layer name as advertised in the WMTS capabilities.
 * @type {string}
 * @api
 */
olx.source.WMTSOptions.prototype.layer;
 
 
/**
 * Style name as advertised in the WMTS capabilities.
 * @type {string}
 * @api
 */
olx.source.WMTSOptions.prototype.style;
 
 
/**
 * Class used to instantiate image tiles. Default is {@link ol.ImageTile}.
 * @type {function(new: ol.ImageTile, ol.TileCoord,
 *                 ol.TileState, string, ?string,
 *                 ol.TileLoadFunctionType)|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.tileClass;
 
 
/**
 * The pixel ratio used by the tile service. For example, if the tile
 * service advertizes 256px by 256px tiles but actually sends 512px
 * by 512px images (for retina/hidpi devices) then `tilePixelRatio`
 * should be set to `2`. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.tilePixelRatio;
 
 
/**
 * WMTS version. Default is `1.0.0`.
 * @type {string|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.version;
 
 
/**
 * Image format. Default is `image/jpeg`.
 * @type {string|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.format;
 
 
/**
 * Matrix set.
 * @type {string}
 * @api
 */
olx.source.WMTSOptions.prototype.matrixSet;
 
 
/**
 * Additional "dimensions" for tile requests.  This is an object with properties
 * named like the advertised WMTS dimensions.
 * @type {!Object|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.dimensions;
 
 
/**
 * A URL for the service.  For the RESTful request encoding, this is a URL
 * template.  For KVP encoding, it is normal URL. A `{?-?}` template pattern,
 * for example `subdomain{a-f}.domain.com`, may be used instead of defining
 * each one separately in the `urls` option.
 * @type {string|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.url;
 
 
/**
 * Optional function to load a tile given a URL. The default is
 * ```js
 * function(imageTile, src) {
 *   imageTile.getImage().src = src;
 * };
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.tileLoadFunction;
 
 
/**
 * An array of URLs.  Requests will be distributed among the URLs in this array.
 * @type {Array.<string>|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.urls;
 
 
/**
 * Whether to wrap the world horizontally. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.WMTSOptions.prototype.wrapX;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     cacheSize: (number|undefined),
 *     crossOrigin: (null|string|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     opaque: (boolean|undefined),
 *     projection: ol.ProjectionLike,
 *     reprojectionErrorThreshold: (number|undefined),
 *     maxZoom: (number|undefined),
 *     minZoom: (number|undefined),
 *     tileGrid: (ol.tilegrid.TileGrid|undefined),
 *     tileLoadFunction: (ol.TileLoadFunctionType|undefined),
 *     tilePixelRatio: (number|undefined),
 *     tileSize: (number|ol.Size|undefined),
 *     tileUrlFunction: (ol.TileUrlFunctionType|undefined),
 *     url: (string|undefined),
 *     urls: (Array.<string>|undefined),
 *     wrapX: (boolean|undefined)}}
 */
olx.source.XYZOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.attributions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.cacheSize;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.crossOrigin;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.logo;
 
 
/**
 * Whether the layer is opaque.
 * @type {boolean|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.opaque;
 
 
/**
 * Projection. Default is `EPSG:3857`.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.XYZOptions.prototype.projection;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * Optional max zoom level. Default is `18`.
 * @type {number|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.maxZoom;
 
 
/**
 * Optional min zoom level. Default is `0`.
 * @type {number|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.minZoom;
 
 
/**
 * Tile grid.
 * @type {ol.tilegrid.TileGrid|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.tileGrid;
 
 
/**
 * Optional function to load a tile given a URL. The default is
 * ```js
 * function(imageTile, src) {
 *   imageTile.getImage().src = src;
 * };
 * ```
 * @type {ol.TileLoadFunctionType|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.tileLoadFunction;
 
 
/**
 * The pixel ratio used by the tile service. For example, if the tile
 * service advertizes 256px by 256px tiles but actually sends 512px
 * by 512px images (for retina/hidpi devices) then `tilePixelRatio`
 * should be set to `2`. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.tilePixelRatio;
 
 
/**
 * The tile size used by the tile service. Default is `[256, 256]` pixels.
 * @type {number|ol.Size|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.tileSize;
 
 
/**
 * Optional function to get tile URL given a tile coordinate and the projection.
 * Required if url or urls are not provided.
 * @type {ol.TileUrlFunctionType|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.tileUrlFunction;
 
 
/**
 * URL template. Must include `{x}`, `{y}` or `{-y}`, and `{z}` placeholders.
 * A `{?-?}` template pattern, for example `subdomain{a-f}.domain.com`, may be
 * used instead of defining each one separately in the `urls` option.
 * @type {string|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.url;
 
 
/**
 * An array of URL templates.
 * @type {Array.<string>|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.urls;
 
 
/**
 * Whether to wrap the world horizontally. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.XYZOptions.prototype.wrapX;
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     cacheSize: (number|undefined),
 *     crossOrigin: (null|string|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     projection: ol.ProjectionLike,
 *     maxZoom: (number|undefined),
 *     minZoom: (number|undefined),
 *     wrapX: (boolean|undefined),
 *     config: (Object|undefined),
 *     map: (string|undefined),
 *     account: string}}
 */
olx.source.CartoDBOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.CartoDBOptions.prototype.attributions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.CartoDBOptions.prototype.cacheSize;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.source.CartoDBOptions.prototype.crossOrigin;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.CartoDBOptions.prototype.logo;
 
 
/**
 * Projection. Default is `EPSG:3857`.
 * @type {ol.ProjectionLike}
 * @api
 */
olx.source.CartoDBOptions.prototype.projection;
 
 
/**
 * Optional max zoom level. Default is `18`.
 * @type {number|undefined}
 * @api
 */
olx.source.CartoDBOptions.prototype.maxZoom;
 
 
/**
 * Minimum zoom.
 * @type {number|undefined}
 * @api
 */
olx.source.CartoDBOptions.prototype.minZoom;
 
 
/**
 * Whether to wrap the world horizontally. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.source.CartoDBOptions.prototype.wrapX;
 
 
/**
 * If using anonymous maps, the CartoDB config to use. See
 * {@link http://docs.cartodb.com/cartodb-platform/maps-api/anonymous-maps/}
 * for more detail.
 * If using named maps, a key-value lookup with the template parameters.
 * See {@link http://docs.cartodb.com/cartodb-platform/maps-api/named-maps/}
 * for more detail.
 * @type {Object|undefined}
 * @api
 */
olx.source.CartoDBOptions.prototype.config;
 
 
/**
 * If using named maps, this will be the name of the template to load.
 * See {@link http://docs.cartodb.com/cartodb-platform/maps-api/named-maps/}
 * for more detail.
 * @type {string|undefined}
 * @api
 */
olx.source.CartoDBOptions.prototype.map;
 
 
/**
 * CartoDB account name
 * @type {string}
 * @api
 */
olx.source.CartoDBOptions.prototype.account;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *     cacheSize: (number|undefined),
 *     crossOrigin: (null|string|undefined),
 *     logo: (string|olx.LogoOptions|undefined),
 *     projection: (ol.ProjectionLike|undefined),
 *     reprojectionErrorThreshold: (number|undefined),
 *     url: !string,
 *     tierSizeCalculation: (string|undefined),
 *     size: ol.Size}}
 */
olx.source.ZoomifyOptions;
 
 
/**
 * Attributions.
 * @type {ol.AttributionLike|undefined}
 * @api
 */
olx.source.ZoomifyOptions.prototype.attributions;
 
 
/**
 * Cache size. Default is `2048`.
 * @type {number|undefined}
 * @api
 */
olx.source.ZoomifyOptions.prototype.cacheSize;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.source.ZoomifyOptions.prototype.crossOrigin;
 
 
/**
 * Logo.
 * @type {string|olx.LogoOptions|undefined}
 * @api
 */
olx.source.ZoomifyOptions.prototype.logo;
 
 
/**
 * Projection.
 * @type {ol.ProjectionLike|undefined}
 * @api
 */
olx.source.ZoomifyOptions.prototype.projection;
 
 
/**
 * Maximum allowed reprojection error (in pixels). Default is `0.5`.
 * Higher values can increase reprojection performance, but decrease precision.
 * @type {number|undefined}
 * @api
 */
olx.source.ZoomifyOptions.prototype.reprojectionErrorThreshold;
 
 
/**
 * URL template or base URL of the Zoomify service. A base URL is the fixed part
 * of the URL, excluding the tile group, z, x, and y folder structure, e.g.
 * `http://my.zoomify.info/IMAGE.TIF/`. A URL template must include
 * `{TileGroup}`, `{x}`, `{y}`, and `{z}` placeholders, e.g.
 * `http://my.zoomify.info/IMAGE.TIF/{TileGroup}/{z}-{x}-{y}.jpg`.
 * A `{?-?}` template pattern, for example `subdomain{a-f}.domain.com`, may be
 * used instead of defining each one separately in the `urls` option.
 * @type {!string}
 * @api
 */
olx.source.ZoomifyOptions.prototype.url;
 
 
/**
 * Tier size calculation method: `default` or `truncated`.
 * @type {string|undefined}
 * @api
 */
olx.source.ZoomifyOptions.prototype.tierSizeCalculation;
 
 
/**
 * Size of the image.
 * @type {ol.Size}
 * @api
 */
olx.source.ZoomifyOptions.prototype.size;
 
 
/**
 * Namespace.
 * @type {Object}
 */
olx.style;
 
 
/**
 * @typedef {{fill: (ol.style.Fill|undefined),
 *     radius: number,
 *     snapToPixel: (boolean|undefined),
 *     stroke: (ol.style.Stroke|undefined),
 *     atlasManager: (ol.style.AtlasManager|undefined)}}
 */
olx.style.CircleOptions;
 
 
/**
 * Fill style.
 * @type {ol.style.Fill|undefined}
 * @api
 */
olx.style.CircleOptions.prototype.fill;
 
 
/**
 * Circle radius.
 * @type {number}
 * @api
 */
olx.style.CircleOptions.prototype.radius;
 
 
/**
 * If `true` integral numbers of pixels are used as the X and Y pixel
 * coordinate when drawing the circle in the output canvas. If `false`
 * fractional numbers may be used. Using `true` allows for "sharp"
 * rendering (no blur), while using `false` allows for "accurate"
 * rendering. Note that accuracy is important if the circle's
 * position is animated. Without it, the circle may jitter noticeably.
 * Default value is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.style.CircleOptions.prototype.snapToPixel;
 
 
/**
 * Stroke style.
 * @type {ol.style.Stroke|undefined}
 * @api
 */
olx.style.CircleOptions.prototype.stroke;
 
 
/**
 * The atlas manager to use for this circle. When using WebGL it is
 * recommended to use an atlas manager to avoid texture switching.
 * If an atlas manager is given, the circle is added to an atlas.
 * By default no atlas manager is used.
 * @type {ol.style.AtlasManager|undefined}
 */
olx.style.CircleOptions.prototype.atlasManager;
 
 
/**
 * @typedef {{color: (ol.Color|ol.ColorLike|undefined)}}
 */
olx.style.FillOptions;
 
 
/**
 * A color, gradient or pattern. See {@link ol.color}
 * and {@link ol.colorlike} for possible formats. Default null;
 * if null, the Canvas/renderer default black will be used.
 * @type {ol.Color|ol.ColorLike|undefined}
 * @api
 */
olx.style.FillOptions.prototype.color;
 
 
/**
 * @typedef {{anchor: (Array.<number>|undefined),
 *     anchorOrigin: (ol.style.IconOrigin|undefined),
 *     anchorXUnits: (ol.style.IconAnchorUnits|undefined),
 *     anchorYUnits: (ol.style.IconAnchorUnits|undefined),
 *     color: (ol.Color|string|undefined),
 *     crossOrigin: (null|string|undefined),
 *     img: (Image|HTMLCanvasElement|undefined),
 *     offset: (Array.<number>|undefined),
 *     offsetOrigin: (ol.style.IconOrigin|undefined),
 *     opacity: (number|undefined),
 *     scale: (number|undefined),
 *     snapToPixel: (boolean|undefined),
 *     rotateWithView: (boolean|undefined),
 *     rotation: (number|undefined),
 *     size: (ol.Size|undefined),
 *     imgSize: (ol.Size|undefined),
 *     src: (string|undefined)}}
 */
olx.style.IconOptions;
 
 
/**
 * Anchor. Default value is `[0.5, 0.5]` (icon center).
 * @type {Array.<number>|undefined}
 * @api
 */
olx.style.IconOptions.prototype.anchor;
 
 
/**
 * Origin of the anchor: `bottom-left`, `bottom-right`, `top-left` or
 * `top-right`. Default is `top-left`.
 * @type {ol.style.IconOrigin|undefined}
 * @api
 */
olx.style.IconOptions.prototype.anchorOrigin;
 
 
/**
 * Units in which the anchor x value is specified. A value of `'fraction'`
 * indicates the x value is a fraction of the icon. A value of `'pixels'`
 * indicates the x value in pixels. Default is `'fraction'`.
 * @type {ol.style.IconAnchorUnits|undefined}
 * @api
 */
olx.style.IconOptions.prototype.anchorXUnits;
 
 
/**
 * Units in which the anchor y value is specified. A value of `'fraction'`
 * indicates the y value is a fraction of the icon. A value of `'pixels'`
 * indicates the y value in pixels. Default is `'fraction'`.
 * @type {ol.style.IconAnchorUnits|undefined}
 * @api
 */
olx.style.IconOptions.prototype.anchorYUnits;
 
 
/**
 * Color to tint the icon. If not specified, the icon will be left as is.
 * @type {ol.Color|string|undefined}
 * @api
 */
olx.style.IconOptions.prototype.color;
 
 
/**
 * The `crossOrigin` attribute for loaded images.  Note that you must provide a
 * `crossOrigin` value if you are using the WebGL renderer or if you want to
 * access pixel data with the Canvas renderer.  See
 * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image}
 * for more detail.
 * @type {null|string|undefined}
 * @api
 */
olx.style.IconOptions.prototype.crossOrigin;
 
 
/**
 * Image object for the icon. If the `src` option is not provided then the
 * provided image must already be loaded. And in that case, it is required
 * to provide the size of the image, with the `imgSize` option.
 * @type {Image|HTMLCanvasElement|undefined}
 * @api
 */
olx.style.IconOptions.prototype.img;
 
 
/**
 * Offset, which, together with the size and the offset origin,
 * define the sub-rectangle to use from the original icon image. Default value
 * is `[0, 0]`.
 * @type {Array.<number>|undefined}
 * @api
 */
olx.style.IconOptions.prototype.offset;
 
 
/**
 * Origin of the offset: `bottom-left`, `bottom-right`, `top-left` or
 * `top-right`. Default is `top-left`.
 * @type {ol.style.IconOrigin|undefined}
 * @api
 */
olx.style.IconOptions.prototype.offsetOrigin;
 
 
/**
 * Opacity of the icon. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.style.IconOptions.prototype.opacity;
 
 
/**
 * Scale. Default is `1`.
 * @type {number|undefined}
 * @api
 */
olx.style.IconOptions.prototype.scale;
 
 
/**
 * If `true` integral numbers of pixels are used as the X and Y pixel
 * coordinate when drawing the icon in the output canvas. If `false`
 * fractional numbers may be used. Using `true` allows for "sharp"
 * rendering (no blur), while using `false` allows for "accurate"
 * rendering. Note that accuracy is important if the icon's position
 * is animated. Without it, the icon may jitter noticeably. Default
 * value is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.style.IconOptions.prototype.snapToPixel;
 
 
/**
 * Whether to rotate the icon with the view. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.style.IconOptions.prototype.rotateWithView;
 
 
/**
 * Rotation in radians (positive rotation clockwise). Default is `0`.
 * @type {number|undefined}
 * @api
 */
olx.style.IconOptions.prototype.rotation;
 
 
/**
 * Icon size in pixel. Can be used together with `offset` to define the
 * sub-rectangle to use from the origin (sprite) icon image.
 * @type {ol.Size|undefined}
 * @api
 */
olx.style.IconOptions.prototype.size;
 
 
/**
 * Image size in pixels. Only required if `img` is set and `src` is not, and for
 * SVG images in Internet Explorer 11. The provided `imgSize` needs to match
 * the actual size of the image.
 * @type {ol.Size|undefined}
 * @api
 */
olx.style.IconOptions.prototype.imgSize;
 
 
/**
 * Image source URI.
 * @type {string|undefined}
 * @api
 */
olx.style.IconOptions.prototype.src;
 
 
/**
 * Specify radius for regular polygons, or radius1 and radius2 for stars.
 * @typedef {{fill: (ol.style.Fill|undefined),
 *     points: number,
 *     radius: (number|undefined),
 *     radius1: (number|undefined),
 *     radius2: (number|undefined),
 *     angle: (number|undefined),
 *     snapToPixel: (boolean|undefined),
 *     stroke: (ol.style.Stroke|undefined),
 *     rotation: (number|undefined),
 *     rotateWithView: (boolean|undefined),
 *     atlasManager: (ol.style.AtlasManager|undefined)}}
 */
olx.style.RegularShapeOptions;
 
 
/**
 * Fill style.
 * @type {ol.style.Fill|undefined}
 * @api
 */
olx.style.RegularShapeOptions.prototype.fill;
 
 
/**
 * Number of points for stars and regular polygons. In case of a polygon, the
 * number of points is the number of sides.
 * @type {number}
 * @api
 */
olx.style.RegularShapeOptions.prototype.points;
 
 
/**
 * Radius of a regular polygon.
 * @type {number|undefined}
 * @api
 */
olx.style.RegularShapeOptions.prototype.radius;
 
 
/**
 * Outer radius of a star.
 * @type {number|undefined}
 * @api
 */
olx.style.RegularShapeOptions.prototype.radius1;
 
 
/**
 * Inner radius of a star.
 * @type {number|undefined}
 * @api
 */
olx.style.RegularShapeOptions.prototype.radius2;
 
 
/**
 * Shape's angle in radians. A value of 0 will have one of the shape's point
 * facing up.
 * Default value is 0.
 * @type {number|undefined}
 * @api
 */
olx.style.RegularShapeOptions.prototype.angle;
 
 
/**
 * If `true` integral numbers of pixels are used as the X and Y pixel
 * coordinate when drawing the shape in the output canvas. If `false`
 * fractional numbers may be used. Using `true` allows for "sharp"
 * rendering (no blur), while using `false` allows for "accurate"
 * rendering. Note that accuracy is important if the shape's
 * position is animated. Without it, the shape may jitter noticeably.
 * Default value is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.style.RegularShapeOptions.prototype.snapToPixel;
 
 
/**
 * Stroke style.
 * @type {ol.style.Stroke|undefined}
 * @api
 */
olx.style.RegularShapeOptions.prototype.stroke;
 
 
/**
 * Rotation in radians (positive rotation clockwise). Default is `0`.
 * @type {number|undefined}
 * @api
 */
olx.style.RegularShapeOptions.prototype.rotation;
 
 
/**
 * Whether to rotate the shape with the view. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.style.RegularShapeOptions.prototype.rotateWithView;
 
 
/**
 * The atlas manager to use for this symbol. When using WebGL it is
 * recommended to use an atlas manager to avoid texture switching.
 * If an atlas manager is given, the symbol is added to an atlas.
 * By default no atlas manager is used.
 * @type {ol.style.AtlasManager|undefined}
 */
olx.style.RegularShapeOptions.prototype.atlasManager;
 
 
/**
 * @typedef {{color: (ol.Color|ol.ColorLike|undefined),
 *     lineCap: (string|undefined),
 *     lineJoin: (string|undefined),
 *     lineDash: (Array.<number>|undefined),
 *     lineDashOffset: (number|undefined),
 *     miterLimit: (number|undefined),
 *     width: (number|undefined)}}
 */
olx.style.StrokeOptions;
 
 
/**
 * A color, gradient or pattern. See {@link ol.color}
 * and {@link ol.colorlike} for possible formats. Default null;
 * if null, the Canvas/renderer default black will be used.
 * @type {ol.Color|ol.ColorLike|undefined}
 * @api
 */
olx.style.StrokeOptions.prototype.color;
 
 
/**
 * Line cap style: `butt`, `round`, or `square`. Default is `round`.
 * @type {string|undefined}
 * @api
 */
olx.style.StrokeOptions.prototype.lineCap;
 
 
/**
 * Line join style: `bevel`, `round`, or `miter`. Default is `round`.
 * @type {string|undefined}
 * @api
 */
olx.style.StrokeOptions.prototype.lineJoin;
 
 
/**
 * Line dash pattern. Default is `undefined` (no dash). Please note that
 * Internet Explorer 10 and lower [do not support][mdn] the `setLineDash`
 * method on the `CanvasRenderingContext2D` and therefore this option will
 * have no visual effect in these browsers.
 *
 * [mdn]: https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/setLineDash#Browser_compatibility
 *
 * @type {Array.<number>|undefined}
 * @api
 */
olx.style.StrokeOptions.prototype.lineDash;
 
 
/**
 * Line dash offset. Default is '0'.
 * @type {number|undefined}
 * @api
 */
olx.style.StrokeOptions.prototype.lineDashOffset;
 
 
/**
 * Miter limit. Default is `10`.
 * @type {number|undefined}
 * @api
 */
olx.style.StrokeOptions.prototype.miterLimit;
 
 
/**
 * Width.
 * @type {number|undefined}
 * @api
 */
olx.style.StrokeOptions.prototype.width;
 
 
/**
 * @typedef {{font: (string|undefined),
 *     offsetX: (number|undefined),
 *     offsetY: (number|undefined),
 *     scale: (number|undefined),
 *     rotateWithView: (boolean|undefined),
 *     rotation: (number|undefined),
 *     text: (string|undefined),
 *     textAlign: (string|undefined),
 *     textBaseline: (string|undefined),
 *     fill: (ol.style.Fill|undefined),
 *     stroke: (ol.style.Stroke|undefined)}}
 */
olx.style.TextOptions;
 
 
/**
 * Font style as CSS 'font' value, see:
 * {@link https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/font}.
 * Default is '10px sans-serif'
 * @type {string|undefined}
 * @api
 */
olx.style.TextOptions.prototype.font;
 
 
/**
 * Horizontal text offset in pixels. A positive will shift the text right.
 * Default is `0`.
 * @type {number|undefined}
 * @api
 */
olx.style.TextOptions.prototype.offsetX;
 
 
/**
 * Vertical text offset in pixels. A positive will shift the text down. Default
 * is `0`.
 * @type {number|undefined}
 * @api
 */
olx.style.TextOptions.prototype.offsetY;
 
 
/**
 * Scale.
 * @type {number|undefined}
 * @api
 */
olx.style.TextOptions.prototype.scale;
 
 
/**
 * Whether to rotate the text with the view. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.style.TextOptions.prototype.rotateWithView;
 
 
/**
 * Rotation in radians (positive rotation clockwise). Default is `0`.
 * @type {number|undefined}
 * @api
 */
olx.style.TextOptions.prototype.rotation;
 
 
/**
 * Text content.
 * @type {string|undefined}
 * @api
 */
olx.style.TextOptions.prototype.text;
 
 
/**
 * Text alignment. Possible values: 'left', 'right', 'center', 'end' or 'start'.
 * Default is 'start'.
 * @type {string|undefined}
 * @api
 */
olx.style.TextOptions.prototype.textAlign;
 
 
/**
 * Text base line. Possible values: 'bottom', 'top', 'middle', 'alphabetic',
 * 'hanging', 'ideographic'. Default is 'alphabetic'.
 * @type {string|undefined}
 * @api
 */
olx.style.TextOptions.prototype.textBaseline;
 
 
/**
 * Fill style. If none is provided, we'll use a dark fill-style (#333).
 * @type {ol.style.Fill|undefined}
 * @api
 */
olx.style.TextOptions.prototype.fill;
 
 
/**
 * Stroke style.
 * @type {ol.style.Stroke|undefined}
 * @api
 */
olx.style.TextOptions.prototype.stroke;
 
 
/**
 * @typedef {{geometry: (undefined|string|ol.geom.Geometry|ol.StyleGeometryFunction),
 *     fill: (ol.style.Fill|undefined),
 *     image: (ol.style.Image|undefined),
 *     stroke: (ol.style.Stroke|undefined),
 *     text: (ol.style.Text|undefined),
 *     zIndex: (number|undefined)}}
 */
olx.style.StyleOptions;
 
 
/**
 * Feature property or geometry or function returning a geometry to render for
 * this style.
 * @type {undefined|string|ol.geom.Geometry|ol.StyleGeometryFunction}
 * @api
 */
olx.style.StyleOptions.prototype.geometry;
 
 
/**
 * Fill style.
 * @type {ol.style.Fill|undefined}
 * @api
 */
olx.style.StyleOptions.prototype.fill;
 
 
/**
 * Image style.
 * @type {ol.style.Image|undefined}
 * @api
 */
olx.style.StyleOptions.prototype.image;
 
 
/**
 * Stroke style.
 * @type {ol.style.Stroke|undefined}
 * @api
 */
olx.style.StyleOptions.prototype.stroke;
 
 
/**
 * Text style.
 * @type {ol.style.Text|undefined}
 * @api
 */
olx.style.StyleOptions.prototype.text;
 
 
/**
 * Z index.
 * @type {number|undefined}
 * @api
 */
olx.style.StyleOptions.prototype.zIndex;
 
 
/**
 * Namespace.
 * @type {Object}
 */
olx.tilegrid;
 
 
/**
 * @typedef {{extent: (ol.Extent|undefined),
 *     minZoom: (number|undefined),
 *     origin: (ol.Coordinate|undefined),
 *     origins: (Array.<ol.Coordinate>|undefined),
 *     resolutions: !Array.<number>,
 *     sizes: (Array.<ol.Size>|undefined),
 *     tileSize: (number|ol.Size|undefined),
 *     tileSizes: (Array.<number|ol.Size>|undefined)}}
 */
olx.tilegrid.TileGridOptions;
 
 
/**
 * Extent for the tile grid. No tiles outside this extent will be requested by
 * {@link ol.source.Tile} sources. When no `origin` or `origins` are
 * configured, the `origin` will be set to the top-left corner of the extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.tilegrid.TileGridOptions.prototype.extent;
 
 
/**
 * Minimum zoom. Default is 0.
 * @type {number|undefined}
 * @api
 */
olx.tilegrid.TileGridOptions.prototype.minZoom;
 
 
/**
 * The tile grid origin, i.e. where the `x` and `y` axes meet (`[z, 0, 0]`).
 * Tile coordinates increase left to right and upwards. If not specified,
 * `extent` or `origins` must be provided.
 * @type {ol.Coordinate|undefined}
 * @api
 */
olx.tilegrid.TileGridOptions.prototype.origin;
 
 
/**
 * Tile grid origins, i.e. where the `x` and `y` axes meet (`[z, 0, 0]`), for
 * each zoom level. If given, the array length should match the length of the
 * `resolutions` array, i.e. each resolution can have a different origin. Tile
 * coordinates increase left to right and upwards. If not specified, `extent`
 * or `origin` must be provided.
 * @type {Array.<ol.Coordinate>|undefined}
 * @api
 */
olx.tilegrid.TileGridOptions.prototype.origins;
 
 
/**
 * Resolutions. The array index of each resolution needs to match the zoom
 * level. This means that even if a `minZoom` is configured, the resolutions
 * array will have a length of `maxZoom + 1`.
 * @type {!Array.<number>}
 * @api
 */
olx.tilegrid.TileGridOptions.prototype.resolutions;
 
 
/**
 * Tile size. Default is `[256, 256]`.
 * @type {number|ol.Size|undefined}
 * @api
 */
olx.tilegrid.TileGridOptions.prototype.tileSize;
 
 
/**
 * Tile sizes. If given, the array length should match the length of the
 * `resolutions` array, i.e. each resolution can have a different tile size.
 * @type {Array.<number|ol.Size>|undefined}
 * @api
 */
olx.tilegrid.TileGridOptions.prototype.tileSizes;
 
 
/**
 * @typedef {{extent: (ol.Extent|undefined),
 *     origin: (ol.Coordinate|undefined),
 *     origins: (Array.<ol.Coordinate>|undefined),
 *     resolutions: !Array.<number>,
 *     matrixIds: !Array.<string>,
 *     sizes: (Array.<ol.Size>|undefined),
 *     tileSize: (number|ol.Size|undefined),
 *     tileSizes: (Array.<number|ol.Size>|undefined)}}
 */
olx.tilegrid.WMTSOptions;
 
 
/**
 * Extent for the tile grid. No tiles outside this extent will be requested by
 * {@link ol.source.Tile} sources. When no `origin` or `origins` are
 * configured, the `origin` will be set to the top-left corner of the extent.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.tilegrid.WMTSOptions.prototype.extent;
 
 
/**
 * The tile grid origin, i.e. where the `x` and `y` axes meet (`[z, 0, 0]`).
 * Tile coordinates increase left to right and upwards. If not specified,
 * `extent` or `origins` must be provided.
 * @type {ol.Coordinate|undefined}
 * @api
 */
olx.tilegrid.WMTSOptions.prototype.origin;
 
 
/**
 * Tile grid origins, i.e. where the `x` and `y` axes meet (`[z, 0, 0]`), for
 * each zoom level. If given, the array length should match the length of the
 * `resolutions` array, i.e. each resolution can have a different origin. Tile
 * coordinates increase left to right and upwards. If not specified, `extent` or
 * `origin` must be provided.
 * @type {Array.<ol.Coordinate>|undefined}
 * @api
 */
olx.tilegrid.WMTSOptions.prototype.origins;
 
 
/**
 * Resolutions. The array index of each resolution needs to match the zoom
 * level. This means that even if a `minZoom` is configured, the resolutions
 * array will have a length of `maxZoom + 1`
 * @type {!Array.<number>}
 * @api
 */
olx.tilegrid.WMTSOptions.prototype.resolutions;
 
 
/**
 * matrix IDs. The length of this array needs to match the length of the
 * `resolutions` array.
 * @type {!Array.<string>}
 * @api
 */
olx.tilegrid.WMTSOptions.prototype.matrixIds;
 
 
/**
 * Number of tile rows and columns of the grid for each zoom level. The values
 * here are the `TileMatrixWidth` and `TileMatrixHeight` advertised in the
 * GetCapabilities response of the WMTS, and define the grid's extent together
 * with the `origin`. An `extent` can be configured in addition, and will
 * further limit the extent for which tile requests are made by sources. Note
 * that when the top-left corner of the `extent` is used as `origin` or
 * `origins`, then the `y` value must be negative because OpenLayers tile
 * coordinates increase upwards.
 * @type {Array.<ol.Size>|undefined}
 * @api
 */
olx.tilegrid.WMTSOptions.prototype.sizes;
 
 
/**
 * Tile size.
 * @type {number|ol.Size|undefined}
 * @api
 */
olx.tilegrid.WMTSOptions.prototype.tileSize;
 
 
/**
 * Tile sizes. The length of this array needs to match the length of the
 * `resolutions` array.
 * @type {Array.<number|ol.Size>|undefined}
 * @api
 */
olx.tilegrid.WMTSOptions.prototype.tileSizes;
 
 
/**
 * Number of tile columns that cover the grid's extent for each zoom level. Only
 * required when used with a source that has `wrapX` set to `true`, and only
 * when the grid's origin differs from the one of the projection's extent. The
 * array length has to match the length of the `resolutions` array, i.e. each
 * resolution will have a matching entry here.
 * @type {Array.<number>|undefined}
 * @api
 */
olx.tilegrid.WMTSOptions.prototype.widths;
 
 
/**
 * @typedef {{extent: (ol.Extent|undefined),
 *     maxZoom: (number|undefined),
 *     minZoom: (number|undefined),
 *     tileSize: (number|ol.Size|undefined)}}
 */
olx.tilegrid.XYZOptions;
 
 
/**
 * Extent for the tile grid.  The origin for an XYZ tile grid is the top-left
 * corner of the extent.  The zero level of the grid is defined by the
 * resolution at which one tile fits in the provided extent.  If not provided,
 * the extent of the EPSG:3857 projection is used.
 * @type {ol.Extent|undefined}
 * @api
 */
olx.tilegrid.XYZOptions.prototype.extent;
 
 
/**
 * Maximum zoom.  The default is `ol.DEFAULT_MAX_ZOOM`.  This determines the
 * number of levels in the grid set.  For example, a `maxZoom` of 21 means there
 * are 22 levels in the grid set.
 * @type {number|undefined}
 * @api
 */
olx.tilegrid.XYZOptions.prototype.maxZoom;
 
 
/**
 * Minimum zoom. Default is 0.
 * @type {number|undefined}
 * @api
 */
olx.tilegrid.XYZOptions.prototype.minZoom;
 
 
/**
 * Tile size in pixels. Default is `[256, 256]`.
 * @type {number|ol.Size|undefined}
 * @api
 */
olx.tilegrid.XYZOptions.prototype.tileSize;
 
 
/**
 * Namespace.
 * @type {Object}
 */
olx.view;
 
 
/**
 * @typedef {{
 *     size: (ol.Size|undefined),
 *     padding: (!Array.<number>|undefined),
 *     constrainResolution: (boolean|undefined),
 *     nearest: (boolean|undefined),
 *     maxZoom: (number|undefined),
 *     minResolution: (number|undefined),
 *     duration: (number|undefined),
 *     easing: (undefined|function(number):number)
 * }}
 */
olx.view.FitOptions;
 
 
/**
 * The size in pixels of the box to fit the extent into. Default is
 * the current size of the first map in the DOM that uses this view, or
 * `[100, 100]` if no such map is found.
 * @type {ol.Size|undefined}
 * @api
 */
olx.view.FitOptions.prototype.size;
 
 
/**
 * Padding (in pixels) to be cleared inside the view. Values in the array are
 * top, right, bottom and left padding. Default is `[0, 0, 0, 0]`.
 * @type {!Array.<number>|undefined}
 * @api
 */
olx.view.FitOptions.prototype.padding;
 
 
/**
 * Constrain the resolution. Default is `true`.
 * @type {boolean|undefined}
 * @api
 */
olx.view.FitOptions.prototype.constrainResolution;
 
 
/**
 * Get the nearest extent. Default is `false`.
 * @type {boolean|undefined}
 * @api
 */
olx.view.FitOptions.prototype.nearest;
 
 
/**
 * Minimum resolution that we zoom to. Default is `0`.
 * @type {number|undefined}
 * @api
 */
olx.view.FitOptions.prototype.minResolution;
 
 
/**
 * Maximum zoom level that we zoom to. If `minResolution` is given,
 * this property is ignored.
 * @type {number|undefined}
 * @api
 */
olx.view.FitOptions.prototype.maxZoom;
 
 
/**
 * The duration of the animation in milliseconds. By default, there is no
 * animations.
 * @type {number|undefined}
 * @api
 */
olx.view.FitOptions.prototype.duration;
 
 
/**
 * The easing function used during the animation (defaults to {@link ol.easing.inAndOut}).
 * The function will be called for each frame with a number representing a
 * fraction of the animation's duration.  The function should return a number
 * between 0 and 1 representing the progress toward the destination state.
 * @type {undefined|function(number):number}
 * @api
 */
olx.view.FitOptions.prototype.easing;
 
 
/* typedefs for object literals exposed by the library */
 
 
/**
 * @typedef {{animate: boolean,
 *     attributions: Object.<string, ol.Attribution>,
 *     coordinateToPixelTransform: ol.Transform,
 *     extent: (null|ol.Extent),
 *     focus: ol.Coordinate,
 *     index: number,
 *     layerStates: Object.<number, ol.LayerState>,
 *     layerStatesArray: Array.<ol.LayerState>,
 *     logos: Object.<string, (string|Element)>,
 *     pixelRatio: number,
 *     pixelToCoordinateTransform: ol.Transform,
 *     postRenderFunctions: Array.<ol.PostRenderFunction>,
 *     size: ol.Size,
 *     skippedFeatureUids: Object.<string, boolean>,
 *     tileQueue: ol.TileQueue,
 *     time: number,
 *     usedTiles: Object.<string, Object.<string, ol.TileRange>>,
 *     viewState: olx.ViewState,
 *     viewHints: Array.<number>,
 *     wantedTiles: !Object.<string, Object.<string, boolean>>}}
 */
olx.FrameState;
 
 
/**
 * @type {number}
 * @api
 */
olx.FrameState.prototype.pixelRatio;
 
 
/**
 * @type {number}
 * @api
 */
olx.FrameState.prototype.time;
 
 
/**
 * @type {olx.ViewState}
 * @api
 */
olx.FrameState.prototype.viewState;
 
 
/**
 * @typedef {{center: ol.Coordinate,
 *     projection: ol.proj.Projection,
 *     resolution: number,
 *     rotation: number}}
 */
olx.ViewState;
 
 
/**
 * @type {ol.Coordinate}
 * @api
 */
olx.ViewState.prototype.center;
 
 
/**
 * @type {ol.proj.Projection}
 * @api
 */
olx.ViewState.prototype.projection;
 
 
/**
 * @type {number}
 * @api
 */
olx.ViewState.prototype.resolution;
 
 
/**
 * @type {number}
 * @api
 */
olx.ViewState.prototype.rotation;
 
 
/**
 * @typedef {{initialSize: (number|undefined),
 *     maxSize: (number|undefined),
 *     space: (number|undefined)}}
 */
olx.style.AtlasManagerOptions;
 
 
/**
 * The size in pixels of the first atlas image. If no value is given the
 * `ol.INITIAL_ATLAS_SIZE` compile-time constant will be used.
 * @type {number|undefined}
 * @api
 */
olx.style.AtlasManagerOptions.prototype.initialSize;
 
 
/**
 * The maximum size in pixels of atlas images. If no value is given then
 * the `ol.MAX_ATLAS_SIZE` compile-time constant will be used. And if
 * `ol.MAX_ATLAS_SIZE` is set to `-1` (the default) then
 * `ol.WEBGL_MAX_TEXTURE_SIZE` will used if WebGL is supported. Otherwise
 * 2048 is used.
 * @type {number|undefined}
 * @api
 */
olx.style.AtlasManagerOptions.prototype.maxSize;
 
 
/**
 * The space in pixels between images (default: 1).
 * @type {number|undefined}
 * @api
 */
olx.style.AtlasManagerOptions.prototype.space;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/proj4js.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/proj4js.js

Statements: 100% (5 / 5)      Branches: 100% (0 / 0)      Functions: 0% (0 / 4)      Lines: 100% (5 / 5)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39                  1             1             1               1         1    
/**
 * @externs
 * @see http://proj4js.org/
 */
 
 
/**
 * @constructor
 */
var Proj4 = function() {};
 
 
/**
 * @param {ol.Coordinate} coordinates
 * @return {ol.Coordinate}
 */
Proj4.prototype.forward = function(coordinates) {};
 
 
/**
 * @param {ol.Coordinate} coordinates
 * @return {ol.Coordinate}
 */
Proj4.prototype.inverse = function(coordinates) {};
 
 
/**
 * @param {string} name
 * @param {(string|Object)=} opt_def
 * @return {undefined|Object.<string, Object.<{axis: string, units: string, to_meter: number}>>}
 */
Proj4.prototype.defs = function(name, opt_def) {};
 
/**
 * @type {Proj4}
 */
var proj4;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/tilejson.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/tilejson.js

Statements: 100% (19 / 19)      Branches: 100% (0 / 0)      Functions: 0% (0 / 2)      Lines: 100% (19 / 19)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123                      1           1           1           1           1           1           1           1           1           1           1           1           1           1           1             1           1           1           1    
/**
 * @externs
 * @see https://github.com/mapbox/tilejson-spec
 * @see https://github.com/mapbox/utfgrid-spec
 */
 
 
 
/**
 * @constructor
 */
var TileJSON = function() {};
 
 
/**
 * @type {string}
 */
TileJSON.prototype.tilejson;
 
 
/**
 * @type {string|undefined}
 */
TileJSON.prototype.name;
 
 
/**
 * @type {string|undefined}
 */
TileJSON.prototype.description;
 
 
/**
 * @type {string|undefined}
 */
TileJSON.prototype.version;
 
 
/**
 * @type {string|undefined}
 */
TileJSON.prototype.attribution;
 
 
/**
 * @type {string|undefined}
 */
TileJSON.prototype.template;
 
 
/**
 * @type {string|undefined}
 */
TileJSON.prototype.legend;
 
 
/**
 * @type {string|undefined}
 */
TileJSON.prototype.scheme;
 
 
/**
 * @type {!Array.<string>}
 */
TileJSON.prototype.tiles;
 
 
/**
 * @type {!Array.<string>|undefined}
 */
TileJSON.prototype.grids;
 
 
/**
 * @type {number|undefined}
 */
TileJSON.prototype.minzoom;
 
 
/**
 * @type {number|undefined}
 */
TileJSON.prototype.maxzoom;
 
 
/**
 * @type {!Array.<number>|undefined}
 */
TileJSON.prototype.bounds;
 
 
/**
 * @type {!Array.<number>|undefined}
 */
TileJSON.prototype.center;
 
 
 
/**
 * @constructor
 */
var UTFGridJSON = function() {};
 
 
/**
 * @type {!Array.<string>}
 */
UTFGridJSON.prototype.grid;
 
 
/**
 * @type {!Array.<string>}
 */
UTFGridJSON.prototype.keys;
 
 
/**
 * @type {!Object.<string, Object>|undefined}
 */
UTFGridJSON.prototype.data;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/topojson.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/externs/topojson.js

Statements: 100% (25 / 25)      Branches: 100% (0 / 0)      Functions: 0% (0 / 10)      Lines: 100% (25 / 25)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174                        1           1           1           1           1             1           1           1             1           1           1             1           1               1           1               1           1               1           1               1           1               1           1               1           1    
 
/**
 * @fileoverview Externs for TopoJSON.
 * @see https://github.com/mbostock/topojson/wiki/Specification
 * @externs
 */
 
 
 
/**
 * @constructor
 */
var TopoJSONTopology = function() {};
 
 
/**
 * @type {string}
 */
TopoJSONTopology.prototype.type;
 
 
/**
 * @type {TopoJSONTransform|undefined}
 */
TopoJSONTopology.prototype.transform;
 
 
/**
 * @type {Object.<string, (TopoJSONGeometry|TopoJSONGeometryCollection)>}
 */
TopoJSONTopology.prototype.objects;
 
 
/**
 * @type {!Array.<Array.<Array.<number>>>}
 */
TopoJSONTopology.prototype.arcs;
 
 
 
/**
 * @constructor
 */
var TopoJSONTransform = function() {};
 
 
/**
 * @type {!Array.<number>}
 */
TopoJSONTransform.prototype.scale;
 
 
/**
 * @type {!Array.<number>}
 */
TopoJSONTransform.prototype.translate;
 
 
 
/**
 * @constructor
 */
var TopoJSONGeometry = function() {};
 
 
/**
 * @type {string}
 */
TopoJSONGeometry.prototype.type;
 
 
/**
 * @type {string|number|undefined}
 */
TopoJSONGeometry.prototype.id;
 
 
 
/**
 * @constructor
 */
var TopoJSONGeometryCollection = function() {};
 
 
/**
 * @type {Array.<TopoJSONGeometry>}
 */
TopoJSONGeometryCollection.prototype.geometries;
 
 
 
/**
 * @constructor
 * @extends {TopoJSONGeometry}
 */
var TopoJSONPoint = function() {};
 
 
/**
 * @type {!Array.<number>}
 */
TopoJSONPoint.prototype.coordinates;
 
 
 
/**
 * @constructor
 * @extends {TopoJSONGeometry}
 */
var TopoJSONLineString = function() {};
 
 
/**
 * @type {!Array.<number>}
 */
TopoJSONLineString.prototype.arcs;
 
 
 
/**
 * @constructor
 * @extends {TopoJSONGeometry}
 */
var TopoJSONPolygon = function() {};
 
 
/**
 * @type {!Array.<Array.<number>>}
 */
TopoJSONPolygon.prototype.arcs;
 
 
 
/**
 * @constructor
 * @extends {TopoJSONGeometry}
 */
var TopoJSONMultiPoint = function() {};
 
 
/**
 * @type {!Array.<Array.<number>>}
 */
TopoJSONMultiPoint.prototype.coordinates;
 
 
 
/**
 * @constructor
 * @extends {TopoJSONGeometry}
 */
var TopoJSONMultiLineString = function() {};
 
 
/**
 * @type {!Array.<Array.<number>>}
 */
TopoJSONMultiLineString.prototype.arcs;
 
 
 
/**
 * @constructor
 * @extends {TopoJSONGeometry}
 */
var TopoJSONMultiPolygon = function() {};
 
 
/**
 * @type {!Array.<Array.<Array.<number>>>}
 */
TopoJSONMultiPolygon.prototype.arcs;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/

Statements: 1.9% (77 / 4043)      Branches: 0% (0 / 1435)      Functions: 0% (0 / 595)      Lines: 1.9% (77 / 4043)      Ignored: none     

All files » node-npmtest-openlayers/node_modules/openlayers/src/ol/
File Statements Branches Functions Lines
array.js 1% (1 / 100) 0% (0 / 49) 0% (0 / 15) 1% (1 / 100)
assertionerror.js 12.5% (1 / 8) 0% (0 / 2) 0% (0 / 1) 12.5% (1 / 8)
asserts.js 20% (1 / 5) 0% (0 / 2) 0% (0 / 1) 20% (1 / 5)
attribution.js 3.33% (1 / 30) 0% (0 / 18) 0% (0 / 3) 3.33% (1 / 30)
centerconstraint.js 11.11% (1 / 9) 0% (0 / 2) 0% (0 / 3) 11.11% (1 / 9)
collection.js 1.2% (1 / 83) 0% (0 / 20) 0% (0 / 16) 1.2% (1 / 83)
collectioneventtype.js 50% (1 / 2) 100% (0 / 0) 100% (0 / 0) 50% (1 / 2)
color.js 1.19% (1 / 84) 0% (0 / 34) 0% (0 / 8) 1.19% (1 / 84)
colorlike.js 12.5% (1 / 8) 0% (0 / 5) 0% (0 / 2) 12.5% (1 / 8)
constraints.js 20% (1 / 5) 100% (0 / 0) 0% (0 / 1) 20% (1 / 5)
control.js 5.56% (1 / 18) 0% (0 / 14) 0% (0 / 1) 5.56% (1 / 18)
coordinate.js 1.12% (1 / 89) 0% (0 / 24) 0% (0 / 15) 1.12% (1 / 89)
css.js 20% (1 / 5) 100% (0 / 0) 100% (0 / 0) 20% (1 / 5)
deviceorientation.js 1.92% (1 / 52) 0% (0 / 28) 0% (0 / 10) 1.92% (1 / 52)
disposable.js 11.11% (1 / 9) 0% (0 / 2) 0% (0 / 2) 11.11% (1 / 9)
dom.js 3.7% (1 / 27) 0% (0 / 10) 0% (0 / 6) 3.7% (1 / 27)
easing.js 7.69% (1 / 13) 0% (0 / 2) 0% (0 / 5) 7.69% (1 / 13)
events.js 1.32% (1 / 76) 0% (0 / 42) 0% (0 / 11) 1.32% (1 / 76)
extent.js 0.35% (1 / 283) 0% (0 / 121) 0% (0 / 45) 0.35% (1 / 283)
feature.js 1.22% (1 / 82) 0% (0 / 22) 0% (0 / 16) 1.22% (1 / 82)
featureloader.js 3.13% (1 / 32) 0% (0 / 21) 0% (0 / 6) 3.13% (1 / 32)
functions.js 20% (1 / 5) 100% (0 / 0) 0% (0 / 2) 20% (1 / 5)
geolocation.js 1.12% (1 / 89) 0% (0 / 34) 0% (0 / 19) 1.12% (1 / 89)
geolocationproperty.js 50% (1 / 2) 100% (0 / 0) 100% (0 / 0) 50% (1 / 2)
graticule.js 0.54% (1 / 185) 0% (0 / 44) 0% (0 / 13) 0.54% (1 / 185)
has.js 2.33% (1 / 43) 0% (0 / 24) 0% (0 / 2) 2.33% (1 / 43)
image.js 1.92% (1 / 52) 0% (0 / 14) 0% (0 / 7) 1.92% (1 / 52)
imagebase.js 3.85% (1 / 26) 100% (0 / 0) 0% (0 / 9) 3.85% (1 / 26)
imagecanvas.js 3.85% (1 / 26) 0% (0 / 8) 0% (0 / 5) 3.85% (1 / 26)
imagestate.js 50% (1 / 2) 100% (0 / 0) 100% (0 / 0) 50% (1 / 2)
imagetile.js 2.17% (1 / 46) 0% (0 / 14) 0% (0 / 8) 2.17% (1 / 46)
interaction.js 2.38% (1 / 42) 0% (0 / 34) 0% (0 / 1) 2.38% (1 / 42)
kinetic.js 2.94% (1 / 34) 0% (0 / 6) 0% (0 / 6) 2.94% (1 / 34)
loadingstrategy.js 6.67% (1 / 15) 100% (0 / 0) 0% (0 / 4) 6.67% (1 / 15)
map.js 0.22% (1 / 446) 0% (0 / 182) 0% (0 / 63) 0.22% (1 / 446)
mapbrowserevent.js 6.25% (1 / 16) 0% (0 / 2) 0% (0 / 3) 6.25% (1 / 16)
mapbrowsereventhandler.js 1.09% (1 / 92) 0% (0 / 30) 0% (0 / 11) 1.09% (1 / 92)
mapbrowsereventtype.js 33.33% (1 / 3) 100% (0 / 0) 100% (0 / 0) 33.33% (1 / 3)
mapbrowserpointerevent.js 14.29% (1 / 7) 100% (0 / 0) 0% (0 / 1) 14.29% (1 / 7)
mapevent.js 12.5% (1 / 8) 0% (0 / 2) 0% (0 / 1) 12.5% (1 / 8)
mapeventtype.js 50% (1 / 2) 100% (0 / 0) 100% (0 / 0) 50% (1 / 2)
mapproperty.js 50% (1 / 2) 100% (0 / 0) 100% (0 / 0) 50% (1 / 2)
math.js 1.49% (1 / 67) 0% (0 / 18) 0% (0 / 11) 1.49% (1 / 67)
net.js 10.53% (2 / 19) 0% (0 / 6) 0% (0 / 4) 10.53% (2 / 19)
obj.js 4% (1 / 25) 0% (0 / 12) 0% (0 / 4) 4% (1 / 25)
object.js 1.89% (1 / 53) 0% (0 / 14) 0% (0 / 10) 1.89% (1 / 53)
objecteventtype.js 50% (1 / 2) 100% (0 / 0) 100% (0 / 0) 50% (1 / 2)
observable.js 2.38% (1 / 42) 0% (0 / 8) 0% (0 / 7) 2.38% (1 / 42)
overlay.js 0.62% (1 / 162) 0% (0 / 97) 0% (0 / 23) 0.62% (1 / 162)
overlaypositioning.js 50% (1 / 2) 100% (0 / 0) 100% (0 / 0) 50% (1 / 2)
proj.js 0.65% (1 / 153) 0% (0 / 59) 0% (0 / 28) 0.65% (1 / 153)
render.js 5.88% (1 / 17) 0% (0 / 6) 0% (0 / 1) 5.88% (1 / 17)
reproj.js 1.11% (1 / 90) 0% (0 / 14) 0% (0 / 7) 1.11% (1 / 90)
resolutionconstraint.js 4.17% (1 / 24) 0% (0 / 10) 0% (0 / 4) 4.17% (1 / 24)
rotationconstraint.js 4% (1 / 25) 0% (0 / 12) 0% (0 / 6) 4% (1 / 25)
size.js 4.55% (1 / 22) 0% (0 / 10) 0% (0 / 4) 4.55% (1 / 22)
sphere.js 3.57% (1 / 28) 100% (0 / 0) 0% (0 / 4) 3.57% (1 / 28)
string.js 5.88% (1 / 17) 0% (0 / 14) 0% (0 / 2) 5.88% (1 / 17)
style.js 33.33% (1 / 3) 100% (0 / 0) 100% (0 / 0) 33.33% (1 / 3)
tile.js 2.17% (1 / 46) 0% (0 / 12) 0% (0 / 9) 2.17% (1 / 46)
tilecache.js 5.88% (1 / 17) 0% (0 / 6) 0% (0 / 3) 5.88% (1 / 17)
tilecoord.js 2.5% (1 / 40) 0% (0 / 14) 0% (0 / 5) 2.5% (1 / 40)
tilegrid.js 1.72% (1 / 58) 0% (0 / 16) 0% (0 / 7) 1.72% (1 / 58)
tilequeue.js 2.33% (1 / 43) 0% (0 / 17) 0% (0 / 7) 2.33% (1 / 43)
tilerange.js 2.56% (1 / 39) 0% (0 / 26) 0% (0 / 11) 2.56% (1 / 39)
tilestate.js 50% (1 / 2) 100% (0 / 0) 100% (0 / 0) 50% (1 / 2)
tileurlfunction.js 1.82% (1 / 55) 0% (0 / 10) 0% (0 / 9) 1.82% (1 / 55)
transform.js 1.19% (1 / 84) 100% (0 / 0) 0% (0 / 12) 1.19% (1 / 84)
typedefs.js 1.28% (1 / 78) 100% (0 / 0) 100% (0 / 0) 1.28% (1 / 78)
uri.js 10% (1 / 10) 0% (0 / 6) 0% (0 / 2) 10% (1 / 10)
vectortile.js 1.79% (1 / 56) 0% (0 / 6) 0% (0 / 16) 1.79% (1 / 56)
view.js 0.24% (1 / 423) 0% (0 / 172) 0% (0 / 46) 0.24% (1 / 423)
viewhint.js 50% (1 / 2) 100% (0 / 0) 100% (0 / 0) 50% (1 / 2)
viewproperty.js 50% (1 / 2) 100% (0 / 0) 100% (0 / 0) 50% (1 / 2)
webgl.js 2.13% (1 / 47) 0% (0 / 4) 0% (0 / 1) 2.13% (1 / 47)
xml.js 0.79% (1 / 127) 0% (0 / 54) 0% (0 / 30) 0.79% (1 / 127)
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/array.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/array.js

Statements: 1% (1 / 100)      Branches: 0% (0 / 49)      Functions: 0% (0 / 15)      Lines: 1% (1 / 100)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 2482                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              
goog.provide('ol.array');
 
 
/**
 * Performs a binary search on the provided sorted list and returns the index of the item if found. If it can't be found it'll return -1.
 * https://github.com/darkskyapp/binary-search
 *
 * @param {Array.<*>} haystack Items to search through.
 * @param {*} needle The item to look for.
 * @param {Function=} opt_comparator Comparator function.
 * @return {number} The index of the item if found, -1 if not.
 */
ol.array.binarySearch = function(haystack, needle, opt_comparator) {
  var mid, cmp;
  var comparator = opt_comparator || ol.array.numberSafeCompareFunction;
  var low = 0;
  var high = haystack.length;
  var found = false;
 
  while (low < high) {
    /* Note that "(low + high) >>> 1" may overflow, and results in a typecast
     * to double (which gives the wrong results). */
    mid = low + (high - low >> 1);
    cmp = +comparator(haystack[mid], needle);
 
    if (cmp < 0.0) { /* Too low. */
      low  = mid + 1;
 
    } else { /* Key found or too high */
      high = mid;
      found = !cmp;
    }
  }
 
  /* Key not found. */
  return found ? low : ~low;
};
 
 
/**
 * Compare function for array sort that is safe for numbers.
 * @param {*} a The first object to be compared.
 * @param {*} b The second object to be compared.
 * @return {number} A negative number, zero, or a positive number as the first
 *     argument is less than, equal to, or greater than the second.
 */
ol.array.numberSafeCompareFunction = function(a, b) {
  return a > b ? 1 : a < b ? -1 : 0;
};
 
 
/**
 * Whether the array contains the given object.
 * @param {Array.<*>} arr The array to test for the presence of the element.
 * @param {*} obj The object for which to test.
 * @return {boolean} The object is in the array.
 */
ol.array.includes = function(arr, obj) {
  return arr.indexOf(obj) >= 0;
};
 
 
/**
 * @param {Array.<number>} arr Array.
 * @param {number} target Target.
 * @param {number} direction 0 means return the nearest, > 0
 *    means return the largest nearest, < 0 means return the
 *    smallest nearest.
 * @return {number} Index.
 */
ol.array.linearFindNearest = function(arr, target, direction) {
  var n = arr.length;
  if (arr[0] <= target) {
    return 0;
  } else if (target <= arr[n - 1]) {
    return n - 1;
  } else {
    var i;
    if (direction > 0) {
      for (i = 1; i < n; ++i) {
        if (arr[i] < target) {
          return i - 1;
        }
      }
    } else if (direction < 0) {
      for (i = 1; i < n; ++i) {
        if (arr[i] <= target) {
          return i;
        }
      }
    } else {
      for (i = 1; i < n; ++i) {
        if (arr[i] == target) {
          return i;
        } else if (arr[i] < target) {
          if (arr[i - 1] - target < target - arr[i]) {
            return i - 1;
          } else {
            return i;
          }
        }
      }
    }
    return n - 1;
  }
};
 
 
/**
 * @param {Array.<*>} arr Array.
 * @param {number} begin Begin index.
 * @param {number} end End index.
 */
ol.array.reverseSubArray = function(arr, begin, end) {
  while (begin < end) {
    var tmp = arr[begin];
    arr[begin] = arr[end];
    arr[end] = tmp;
    ++begin;
    --end;
  }
};
 
 
/**
 * @param {Array.<VALUE>} arr The array to modify.
 * @param {Array.<VALUE>|VALUE} data The elements or arrays of elements
 *     to add to arr.
 * @template VALUE
 */
ol.array.extend = function(arr, data) {
  var i;
  var extension = Array.isArray(data) ? data : [data];
  var length = extension.length;
  for (i = 0; i < length; i++) {
    arr[arr.length] = extension[i];
  }
};
 
 
/**
 * @param {Array.<VALUE>} arr The array to modify.
 * @param {VALUE} obj The element to remove.
 * @template VALUE
 * @return {boolean} If the element was removed.
 */
ol.array.remove = function(arr, obj) {
  var i = arr.indexOf(obj);
  var found = i > -1;
  if (found) {
    arr.splice(i, 1);
  }
  return found;
};
 
 
/**
 * @param {Array.<VALUE>} arr The array to search in.
 * @param {function(VALUE, number, ?) : boolean} func The function to compare.
 * @template VALUE
 * @return {VALUE} The element found.
 */
ol.array.find = function(arr, func) {
  var length = arr.length >>> 0;
  var value;
 
  for (var i = 0; i < length; i++) {
    value = arr[i];
    if (func(value, i, arr)) {
      return value;
    }
  }
  return null;
};
 
 
/**
 * @param {Array|Uint8ClampedArray} arr1 The first array to compare.
 * @param {Array|Uint8ClampedArray} arr2 The second array to compare.
 * @return {boolean} Whether the two arrays are equal.
 */
ol.array.equals = function(arr1, arr2) {
  var len1 = arr1.length;
  if (len1 !== arr2.length) {
    return false;
  }
  for (var i = 0; i < len1; i++) {
    if (arr1[i] !== arr2[i]) {
      return false;
    }
  }
  return true;
};
 
 
/**
 * @param {Array.<*>} arr The array to sort (modifies original).
 * @param {Function} compareFnc Comparison function.
 */
ol.array.stableSort = function(arr, compareFnc) {
  var length = arr.length;
  var tmp = Array(arr.length);
  var i;
  for (i = 0; i < length; i++) {
    tmp[i] = {index: i, value: arr[i]};
  }
  tmp.sort(function(a, b) {
    return compareFnc(a.value, b.value) || a.index - b.index;
  });
  for (i = 0; i < arr.length; i++) {
    arr[i] = tmp[i].value;
  }
};
 
 
/**
 * @param {Array.<*>} arr The array to search in.
 * @param {Function} func Comparison function.
 * @return {number} Return index.
 */
ol.array.findIndex = function(arr, func) {
  var index;
  var found = !arr.every(function(el, idx) {
    index = idx;
    return !func(el, idx, arr);
  });
  return found ? index : -1;
};
 
 
/**
 * @param {Array.<*>} arr The array to test.
 * @param {Function=} opt_func Comparison function.
 * @param {boolean=} opt_strict Strictly sorted (default false).
 * @return {boolean} Return index.
 */
ol.array.isSorted = function(arr, opt_func, opt_strict) {
  var compare = opt_func || ol.array.numberSafeCompareFunction;
  return arr.every(function(currentVal, index) {
    if (index === 0) {
      return true;
    }
    var res = compare(arr[index - 1], currentVal);
    return !(res > 0 || opt_strict && res === 0);
  });
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/assertionerror.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/assertionerror.js

Statements: 12.5% (1 / 8)      Branches: 0% (0 / 2)      Functions: 0% (0 / 1)      Lines: 12.5% (1 / 8)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 392                                                                            
goog.provide('ol.AssertionError');
 
goog.require('ol');
 
/**
 * Error object thrown when an assertion failed. This is an ECMA-262 Error,
 * extended with a `code` property.
 * @see {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error}
 * @constructor
 * @extends {Error}
 * @implements {oli.AssertionError}
 * @param {number} code Error code.
 */
ol.AssertionError = function(code) {
 
  var path = ol.VERSION ? ol.VERSION.split('-')[0] : 'latest';
 
  /**
   * @type {string}
   */
  this.message = 'Assertion failed. See https://openlayers.org/en/' + path +
      '/doc/errors/#' + code + ' for details.';
 
  /**
   * Error code. The meaning of the code can be found on
   * {@link https://openlayers.org/en/latest/doc/errors/} (replace `latest` with
   * the version found in the OpenLayers script's header comment if a version
   * other than the latest is used).
   * @type {number}
   * @api
   */
  this.code = code;
 
  this.name = 'AssertionError';
 
};
ol.inherits(ol.AssertionError, Error);
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/asserts.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/asserts.js

Statements: 20% (1 / 5)      Branches: 0% (0 / 2)      Functions: 0% (0 / 1)      Lines: 20% (1 / 5)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 162                              
goog.provide('ol.asserts');
 
goog.require('ol.AssertionError');
 
 
/**
 * @param {*} assertion Assertion we expected to be truthy.
 * @param {number} errorCode Error code.
 */
ol.asserts.assert = function(assertion, errorCode) {
  if (!assertion) {
    throw new ol.AssertionError(errorCode);
  }
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/attribution.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/attribution.js

Statements: 3.33% (1 / 30)      Branches: 0% (0 / 18)      Functions: 0% (0 / 3)      Lines: 3.33% (1 / 30)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 992                                                                                                                                                                                                    
goog.provide('ol.Attribution');
 
goog.require('ol.TileRange');
goog.require('ol.math');
goog.require('ol.tilegrid');
 
 
/**
 * @classdesc
 * An attribution for a layer source.
 *
 * Example:
 *
 *     source: new ol.source.OSM({
 *       attributions: [
 *         new ol.Attribution({
 *           html: 'All maps &copy; ' +
 *               '<a href="https://www.opencyclemap.org/">OpenCycleMap</a>'
 *         }),
 *         ol.source.OSM.ATTRIBUTION
 *       ],
 *     ..
 *
 * @constructor
 * @param {olx.AttributionOptions} options Attribution options.
 * @struct
 * @api
 */
ol.Attribution = function(options) {
 
  /**
   * @private
   * @type {string}
   */
  this.html_ = options.html;
 
  /**
   * @private
   * @type {Object.<string, Array.<ol.TileRange>>}
   */
  this.tileRanges_ = options.tileRanges ? options.tileRanges : null;
 
};
 
 
/**
 * Get the attribution markup.
 * @return {string} The attribution HTML.
 * @api
 */
ol.Attribution.prototype.getHTML = function() {
  return this.html_;
};
 
 
/**
 * @param {Object.<string, ol.TileRange>} tileRanges Tile ranges.
 * @param {!ol.tilegrid.TileGrid} tileGrid Tile grid.
 * @param {!ol.proj.Projection} projection Projection.
 * @return {boolean} Intersects any tile range.
 */
ol.Attribution.prototype.intersectsAnyTileRange = function(tileRanges, tileGrid, projection) {
  if (!this.tileRanges_) {
    return true;
  }
  var i, ii, tileRange, zKey;
  for (zKey in tileRanges) {
    if (!(zKey in this.tileRanges_)) {
      continue;
    }
    tileRange = tileRanges[zKey];
    var testTileRange;
    for (i = 0, ii = this.tileRanges_[zKey].length; i < ii; ++i) {
      testTileRange = this.tileRanges_[zKey][i];
      if (testTileRange.intersects(tileRange)) {
        return true;
      }
      var extentTileRange = tileGrid.getTileRangeForExtentAndZ(
          ol.tilegrid.extentFromProjection(projection), parseInt(zKey, 10));
      var width = extentTileRange.getWidth();
      if (tileRange.minX < extentTileRange.minX ||
          tileRange.maxX > extentTileRange.maxX) {
        if (testTileRange.intersects(new ol.TileRange(
            ol.math.modulo(tileRange.minX, width),
            ol.math.modulo(tileRange.maxX, width),
            tileRange.minY, tileRange.maxY))) {
          return true;
        }
        if (tileRange.getWidth() > width &&
            testTileRange.intersects(extentTileRange)) {
          return true;
        }
      }
    }
  }
  return false;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/centerconstraint.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/centerconstraint.js

Statements: 11.11% (1 / 9)      Branches: 0% (0 / 2)      Functions: 0% (0 / 3)      Lines: 11.11% (1 / 9)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 372                                                                        
goog.provide('ol.CenterConstraint');
 
goog.require('ol.math');
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @return {ol.CenterConstraintType} The constraint.
 */
ol.CenterConstraint.createExtent = function(extent) {
  return (
      /**
       * @param {ol.Coordinate|undefined} center Center.
       * @return {ol.Coordinate|undefined} Center.
       */
      function(center) {
        if (center) {
          return [
            ol.math.clamp(center[0], extent[0], extent[2]),
            ol.math.clamp(center[1], extent[1], extent[3])
          ];
        } else {
          return undefined;
        }
      });
};
 
 
/**
 * @param {ol.Coordinate|undefined} center Center.
 * @return {ol.Coordinate|undefined} Center.
 */
ol.CenterConstraint.none = function(center) {
  return center;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/collection.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/collection.js

Statements: 1.2% (1 / 83)      Branches: 0% (0 / 20)      Functions: 0% (0 / 16)      Lines: 1.2% (1 / 83)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300          2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            
/**
 * An implementation of Google Maps' MVCArray.
 * @see https://developers.google.com/maps/documentation/javascript/reference
 */
 
goog.provide('ol.Collection');
 
goog.require('ol');
goog.require('ol.AssertionError');
goog.require('ol.CollectionEventType');
goog.require('ol.Object');
goog.require('ol.events.Event');
 
 
/**
 * @classdesc
 * An expanded version of standard JS Array, adding convenience methods for
 * manipulation. Add and remove changes to the Collection trigger a Collection
 * event. Note that this does not cover changes to the objects _within_ the
 * Collection; they trigger events on the appropriate object, not on the
 * Collection as a whole.
 *
 * @constructor
 * @extends {ol.Object}
 * @fires ol.Collection.Event
 * @param {!Array.<T>=} opt_array Array.
 * @param {olx.CollectionOptions=} opt_options Collection options.
 * @template T
 * @api
 */
ol.Collection = function(opt_array, opt_options) {
 
  ol.Object.call(this);
 
  var options = opt_options || {};
 
  /**
   * @private
   * @type {boolean}
   */
  this.unique_ = !!options.unique;
 
  /**
   * @private
   * @type {!Array.<T>}
   */
  this.array_ = opt_array ? opt_array : [];
 
  if (this.unique_) {
    for (var i = 0, ii = this.array_.length; i < ii; ++i) {
      this.assertUnique_(this.array_[i], i);
    }
  }
 
  this.updateLength_();
 
};
ol.inherits(ol.Collection, ol.Object);
 
 
/**
 * Remove all elements from the collection.
 * @api
 */
ol.Collection.prototype.clear = function() {
  while (this.getLength() > 0) {
    this.pop();
  }
};
 
 
/**
 * Add elements to the collection.  This pushes each item in the provided array
 * to the end of the collection.
 * @param {!Array.<T>} arr Array.
 * @return {ol.Collection.<T>} This collection.
 * @api
 */
ol.Collection.prototype.extend = function(arr) {
  var i, ii;
  for (i = 0, ii = arr.length; i < ii; ++i) {
    this.push(arr[i]);
  }
  return this;
};
 
 
/**
 * Iterate over each element, calling the provided callback.
 * @param {function(this: S, T, number, Array.<T>): *} f The function to call
 *     for every element. This function takes 3 arguments (the element, the
 *     index and the array). The return value is ignored.
 * @param {S=} opt_this The object to use as `this` in `f`.
 * @template S
 * @api
 */
ol.Collection.prototype.forEach = function(f, opt_this) {
  this.array_.forEach(f, opt_this);
};
 
 
/**
 * Get a reference to the underlying Array object. Warning: if the array
 * is mutated, no events will be dispatched by the collection, and the
 * collection's "length" property won't be in sync with the actual length
 * of the array.
 * @return {!Array.<T>} Array.
 * @api
 */
ol.Collection.prototype.getArray = function() {
  return this.array_;
};
 
 
/**
 * Get the element at the provided index.
 * @param {number} index Index.
 * @return {T} Element.
 * @api
 */
ol.Collection.prototype.item = function(index) {
  return this.array_[index];
};
 
 
/**
 * Get the length of this collection.
 * @return {number} The length of the array.
 * @observable
 * @api
 */
ol.Collection.prototype.getLength = function() {
  return /** @type {number} */ (this.get(ol.Collection.Property_.LENGTH));
};
 
 
/**
 * Insert an element at the provided index.
 * @param {number} index Index.
 * @param {T} elem Element.
 * @api
 */
ol.Collection.prototype.insertAt = function(index, elem) {
  if (this.unique_) {
    this.assertUnique_(elem);
  }
  this.array_.splice(index, 0, elem);
  this.updateLength_();
  this.dispatchEvent(
      new ol.Collection.Event(ol.CollectionEventType.ADD, elem));
};
 
 
/**
 * Remove the last element of the collection and return it.
 * Return `undefined` if the collection is empty.
 * @return {T|undefined} Element.
 * @api
 */
ol.Collection.prototype.pop = function() {
  return this.removeAt(this.getLength() - 1);
};
 
 
/**
 * Insert the provided element at the end of the collection.
 * @param {T} elem Element.
 * @return {number} New length of the collection.
 * @api
 */
ol.Collection.prototype.push = function(elem) {
  if (this.unique_) {
    this.assertUnique_(elem);
  }
  var n = this.getLength();
  this.insertAt(n, elem);
  return this.getLength();
};
 
 
/**
 * Remove the first occurrence of an element from the collection.
 * @param {T} elem Element.
 * @return {T|undefined} The removed element or undefined if none found.
 * @api
 */
ol.Collection.prototype.remove = function(elem) {
  var arr = this.array_;
  var i, ii;
  for (i = 0, ii = arr.length; i < ii; ++i) {
    if (arr[i] === elem) {
      return this.removeAt(i);
    }
  }
  return undefined;
};
 
 
/**
 * Remove the element at the provided index and return it.
 * Return `undefined` if the collection does not contain this index.
 * @param {number} index Index.
 * @return {T|undefined} Value.
 * @api
 */
ol.Collection.prototype.removeAt = function(index) {
  var prev = this.array_[index];
  this.array_.splice(index, 1);
  this.updateLength_();
  this.dispatchEvent(
      new ol.Collection.Event(ol.CollectionEventType.REMOVE, prev));
  return prev;
};
 
 
/**
 * Set the element at the provided index.
 * @param {number} index Index.
 * @param {T} elem Element.
 * @api
 */
ol.Collection.prototype.setAt = function(index, elem) {
  var n = this.getLength();
  if (index < n) {
    if (this.unique_) {
      this.assertUnique_(elem, index);
    }
    var prev = this.array_[index];
    this.array_[index] = elem;
    this.dispatchEvent(
        new ol.Collection.Event(ol.CollectionEventType.REMOVE, prev));
    this.dispatchEvent(
        new ol.Collection.Event(ol.CollectionEventType.ADD, elem));
  } else {
    var j;
    for (j = n; j < index; ++j) {
      this.insertAt(j, undefined);
    }
    this.insertAt(index, elem);
  }
};
 
 
/**
 * @private
 */
ol.Collection.prototype.updateLength_ = function() {
  this.set(ol.Collection.Property_.LENGTH, this.array_.length);
};
 
 
/**
 * @private
 * @param {T} elem Element.
 * @param {number=} opt_except Optional index to ignore.
 */
ol.Collection.prototype.assertUnique_ = function(elem, opt_except) {
  for (var i = 0, ii = this.array_.length; i < ii; ++i) {
    if (this.array_[i] === elem && i !== opt_except) {
      throw new ol.AssertionError(58);
    }
  }
};
 
 
/**
 * @enum {string}
 * @private
 */
ol.Collection.Property_ = {
  LENGTH: 'length'
};
 
 
/**
 * @classdesc
 * Events emitted by {@link ol.Collection} instances are instances of this
 * type.
 *
 * @constructor
 * @extends {ol.events.Event}
 * @implements {oli.Collection.Event}
 * @param {ol.CollectionEventType} type Type.
 * @param {*=} opt_element Element.
 */
ol.Collection.Event = function(type, opt_element) {
 
  ol.events.Event.call(this, type);
 
  /**
   * The element that is added to or removed from the collection.
   * @type {*}
   * @api
   */
  this.element = opt_element;
 
};
ol.inherits(ol.Collection.Event, ol.events.Event);
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/collectioneventtype.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/collectioneventtype.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 212                                        
goog.provide('ol.CollectionEventType');
 
/**
 * @enum {string}
 */
ol.CollectionEventType = {
  /**
   * Triggered when an item is added to the collection.
   * @event ol.Collection.Event#add
   * @api
   */
  ADD: 'add',
  /**
   * Triggered when an item is removed from the collection.
   * @event ol.Collection.Event#remove
   * @api
   */
  REMOVE: 'remove'
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/color.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/color.js

Statements: 1.19% (1 / 84)      Branches: 0% (0 / 34)      Functions: 0% (0 / 8)      Lines: 1.19% (1 / 84)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 2032                                                                                                                                                                                                                                                                                                                                                                                                                    
goog.provide('ol.color');
 
goog.require('ol.asserts');
goog.require('ol.math');
 
 
/**
 * This RegExp matches # followed by 3 or 6 hex digits.
 * @const
 * @type {RegExp}
 * @private
 */
ol.color.HEX_COLOR_RE_ = /^#(?:[0-9a-f]{3}){1,2}$/i;
 
 
/**
 * Regular expression for matching potential named color style strings.
 * @const
 * @type {RegExp}
 * @private
 */
ol.color.NAMED_COLOR_RE_ = /^([a-z]*)$/i;
 
 
/**
 * Return the color as an array. This function maintains a cache of calculated
 * arrays which means the result should not be modified.
 * @param {ol.Color|string} color Color.
 * @return {ol.Color} Color.
 * @api
 */
ol.color.asArray = function(color) {
  if (Array.isArray(color)) {
    return color;
  } else {
    return ol.color.fromString(/** @type {string} */ (color));
  }
};
 
 
/**
 * Return the color as an rgba string.
 * @param {ol.Color|string} color Color.
 * @return {string} Rgba string.
 * @api
 */
ol.color.asString = function(color) {
  if (typeof color === 'string') {
    return color;
  } else {
    return ol.color.toString(color);
  }
};
 
/**
 * Return named color as an rgba string.
 * @param {string} color Named color.
 * @return {string} Rgb string.
 */
ol.color.fromNamed = function(color) {
  var el = document.createElement('div');
  el.style.color = color;
  document.body.appendChild(el);
  var rgb = getComputedStyle(el).color;
  document.body.removeChild(el);
  return rgb;
};
 
 
/**
 * @param {string} s String.
 * @return {ol.Color} Color.
 */
ol.color.fromString = (
    function() {
 
      // We maintain a small cache of parsed strings.  To provide cheap LRU-like
      // semantics, whenever the cache grows too large we simply delete an
      // arbitrary 25% of the entries.
 
      /**
       * @const
       * @type {number}
       */
      var MAX_CACHE_SIZE = 1024;
 
      /**
       * @type {Object.<string, ol.Color>}
       */
      var cache = {};
 
      /**
       * @type {number}
       */
      var cacheSize = 0;
 
      return (
          /**
           * @param {string} s String.
           * @return {ol.Color} Color.
           */
          function(s) {
            var color;
            if (cache.hasOwnProperty(s)) {
              color = cache[s];
            } else {
              if (cacheSize >= MAX_CACHE_SIZE) {
                var i = 0;
                var key;
                for (key in cache) {
                  if ((i++ & 3) === 0) {
                    delete cache[key];
                    --cacheSize;
                  }
                }
              }
              color = ol.color.fromStringInternal_(s);
              cache[s] = color;
              ++cacheSize;
            }
            return color;
          });
 
    })();
 
 
/**
 * @param {string} s String.
 * @private
 * @return {ol.Color} Color.
 */
ol.color.fromStringInternal_ = function(s) {
  var r, g, b, a, color, parts;
 
  if (ol.color.NAMED_COLOR_RE_.exec(s)) {
    s = ol.color.fromNamed(s);
  }
 
  if (ol.color.HEX_COLOR_RE_.exec(s)) { // hex
    var n = s.length - 1; // number of hex digits
    ol.asserts.assert(n == 3 || n == 6, 54); // Hex color should have 3 or 6 digits
    var d = n == 3 ? 1 : 2; // number of digits per channel
    r = parseInt(s.substr(1 + 0 * d, d), 16);
    g = parseInt(s.substr(1 + 1 * d, d), 16);
    b = parseInt(s.substr(1 + 2 * d, d), 16);
    if (d == 1) {
      r = (r << 4) + r;
      g = (g << 4) + g;
      b = (b << 4) + b;
    }
    a = 1;
    color = [r, g, b, a];
  } else if (s.indexOf('rgba(') == 0) { // rgba()
    parts = s.slice(5, -1).split(',').map(Number);
    color = ol.color.normalize(parts);
  } else if (s.indexOf('rgb(') == 0) { // rgb()
    parts = s.slice(4, -1).split(',').map(Number);
    parts.push(1);
    color = ol.color.normalize(parts);
  } else {
    ol.asserts.assert(false, 14); // Invalid color
  }
  return /** @type {ol.Color} */ (color);
};
 
 
/**
 * @param {ol.Color} color Color.
 * @param {ol.Color=} opt_color Color.
 * @return {ol.Color} Clamped color.
 */
ol.color.normalize = function(color, opt_color) {
  var result = opt_color || [];
  result[0] = ol.math.clamp((color[0] + 0.5) | 0, 0, 255);
  result[1] = ol.math.clamp((color[1] + 0.5) | 0, 0, 255);
  result[2] = ol.math.clamp((color[2] + 0.5) | 0, 0, 255);
  result[3] = ol.math.clamp(color[3], 0, 1);
  return result;
};
 
 
/**
 * @param {ol.Color} color Color.
 * @return {string} String.
 */
ol.color.toString = function(color) {
  var r = color[0];
  if (r != (r | 0)) {
    r = (r + 0.5) | 0;
  }
  var g = color[1];
  if (g != (g | 0)) {
    g = (g + 0.5) | 0;
  }
  var b = color[2];
  if (b != (b | 0)) {
    b = (b + 0.5) | 0;
  }
  var a = color[3] === undefined ? 1 : color[3];
  return 'rgba(' + r + ',' + g + ',' + b + ',' + a + ')';
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/colorlike.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/colorlike.js

Statements: 12.5% (1 / 8)      Branches: 0% (0 / 5)      Functions: 0% (0 / 2)      Lines: 12.5% (1 / 8)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 322                                                              
goog.provide('ol.colorlike');
 
goog.require('ol.color');
 
 
/**
 * @param {ol.Color|ol.ColorLike} color Color.
 * @return {ol.ColorLike} The color as an ol.ColorLike
 * @api
 */
ol.colorlike.asColorLike = function(color) {
  if (ol.colorlike.isColorLike(color)) {
    return /** @type {string|CanvasPattern|CanvasGradient} */ (color);
  } else {
    return ol.color.asString(/** @type {ol.Color} */ (color));
  }
};
 
 
/**
 * @param {?} color The value that is potentially an ol.ColorLike
 * @return {boolean} Whether the color is an ol.ColorLike
 */
ol.colorlike.isColorLike = function(color) {
  return (
      typeof color === 'string' ||
      color instanceof CanvasPattern ||
      color instanceof CanvasGradient
  );
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/constraints.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/constraints.js

Statements: 20% (1 / 5)      Branches: 100% (0 / 0)      Functions: 0% (0 / 1)      Lines: 20% (1 / 5)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 312                                                            
goog.provide('ol.Constraints');
 
 
/**
 * @constructor
 * @param {ol.CenterConstraintType} centerConstraint Center constraint.
 * @param {ol.ResolutionConstraintType} resolutionConstraint
 *     Resolution constraint.
 * @param {ol.RotationConstraintType} rotationConstraint
 *     Rotation constraint.
 */
ol.Constraints = function(centerConstraint, resolutionConstraint, rotationConstraint) {
 
  /**
   * @type {ol.CenterConstraintType}
   */
  this.center = centerConstraint;
 
  /**
   * @type {ol.ResolutionConstraintType}
   */
  this.resolution = resolutionConstraint;
 
  /**
   * @type {ol.RotationConstraintType}
   */
  this.rotation = rotationConstraint;
 
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/control.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/control.js

Statements: 5.56% (1 / 18)      Branches: 0% (0 / 14)      Functions: 0% (0 / 1)      Lines: 5.56% (1 / 18)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 472                                                                                            
goog.provide('ol.control');
 
goog.require('ol.Collection');
goog.require('ol.control.Attribution');
goog.require('ol.control.Rotate');
goog.require('ol.control.Zoom');
 
 
/**
 * Set of controls included in maps by default. Unless configured otherwise,
 * this returns a collection containing an instance of each of the following
 * controls:
 * * {@link ol.control.Zoom}
 * * {@link ol.control.Rotate}
 * * {@link ol.control.Attribution}
 *
 * @param {olx.control.DefaultsOptions=} opt_options Defaults options.
 * @return {ol.Collection.<ol.control.Control>} Controls.
 * @api
 */
ol.control.defaults = function(opt_options) {
 
  var options = opt_options ? opt_options : {};
 
  var controls = new ol.Collection();
 
  var zoomControl = options.zoom !== undefined ? options.zoom : true;
  if (zoomControl) {
    controls.push(new ol.control.Zoom(options.zoomOptions));
  }
 
  var rotateControl = options.rotate !== undefined ? options.rotate : true;
  if (rotateControl) {
    controls.push(new ol.control.Rotate(options.rotateOptions));
  }
 
  var attributionControl = options.attribution !== undefined ?
      options.attribution : true;
  if (attributionControl) {
    controls.push(new ol.control.Attribution(options.attributionOptions));
  }
 
  return controls;
 
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/coordinate.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/coordinate.js

Statements: 1.12% (1 / 89)      Branches: 0% (0 / 24)      Functions: 0% (0 / 15)      Lines: 1.12% (1 / 89)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 3492                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        
goog.provide('ol.coordinate');
 
goog.require('ol.math');
goog.require('ol.string');
 
 
/**
 * Add `delta` to `coordinate`. `coordinate` is modified in place and returned
 * by the function.
 *
 * Example:
 *
 *     var coord = [7.85, 47.983333];
 *     ol.coordinate.add(coord, [-2, 4]);
 *     // coord is now [5.85, 51.983333]
 *
 * @param {ol.Coordinate} coordinate Coordinate.
 * @param {ol.Coordinate} delta Delta.
 * @return {ol.Coordinate} The input coordinate adjusted by the given delta.
 * @api
 */
ol.coordinate.add = function(coordinate, delta) {
  coordinate[0] += delta[0];
  coordinate[1] += delta[1];
  return coordinate;
};
 
 
/**
 * Calculates the point closest to the passed coordinate on the passed segment.
 * This is the foot of the perpendicular of the coordinate to the segment when
 * the foot is on the segment, or the closest segment coordinate when the foot
 * is outside the segment.
 *
 * @param {ol.Coordinate} coordinate The coordinate.
 * @param {Array.<ol.Coordinate>} segment The two coordinates of the segment.
 * @return {ol.Coordinate} The foot of the perpendicular of the coordinate to
 *     the segment.
 */
ol.coordinate.closestOnSegment = function(coordinate, segment) {
  var x0 = coordinate[0];
  var y0 = coordinate[1];
  var start = segment[0];
  var end = segment[1];
  var x1 = start[0];
  var y1 = start[1];
  var x2 = end[0];
  var y2 = end[1];
  var dx = x2 - x1;
  var dy = y2 - y1;
  var along = (dx === 0 && dy === 0) ? 0 :
      ((dx * (x0 - x1)) + (dy * (y0 - y1))) / ((dx * dx + dy * dy) || 0);
  var x, y;
  if (along <= 0) {
    x = x1;
    y = y1;
  } else if (along >= 1) {
    x = x2;
    y = y2;
  } else {
    x = x1 + along * dx;
    y = y1 + along * dy;
  }
  return [x, y];
};
 
 
/**
 * Returns a {@link ol.CoordinateFormatType} function that can be used to format
 * a {ol.Coordinate} to a string.
 *
 * Example without specifying the fractional digits:
 *
 *     var coord = [7.85, 47.983333];
 *     var stringifyFunc = ol.coordinate.createStringXY();
 *     var out = stringifyFunc(coord);
 *     // out is now '8, 48'
 *
 * Example with explicitly specifying 2 fractional digits:
 *
 *     var coord = [7.85, 47.983333];
 *     var stringifyFunc = ol.coordinate.createStringXY(2);
 *     var out = stringifyFunc(coord);
 *     // out is now '7.85, 47.98'
 *
 * @param {number=} opt_fractionDigits The number of digits to include
 *    after the decimal point. Default is `0`.
 * @return {ol.CoordinateFormatType} Coordinate format.
 * @api
 */
ol.coordinate.createStringXY = function(opt_fractionDigits) {
  return (
      /**
       * @param {ol.Coordinate|undefined} coordinate Coordinate.
       * @return {string} String XY.
       */
      function(coordinate) {
        return ol.coordinate.toStringXY(coordinate, opt_fractionDigits);
      });
};
 
 
/**
 * @private
 * @param {number} degrees Degrees.
 * @param {string} hemispheres Hemispheres.
 * @param {number=} opt_fractionDigits The number of digits to include
 *    after the decimal point. Default is `0`.
 * @return {string} String.
 */
ol.coordinate.degreesToStringHDMS_ = function(degrees, hemispheres, opt_fractionDigits) {
  var normalizedDegrees = ol.math.modulo(degrees + 180, 360) - 180;
  var x = Math.abs(3600 * normalizedDegrees);
  var dflPrecision = opt_fractionDigits || 0;
  var precision = Math.pow(10, dflPrecision);
 
  var deg = Math.floor(x / 3600);
  var min = Math.floor((x - deg * 3600) / 60);
  var sec = x - (deg * 3600) - (min * 60);
  sec = Math.ceil(sec * precision) / precision;
 
  if (sec >= 60) {
    sec = 0;
    min += 1;
  }
 
  if (min >= 60) {
    min = 0;
    deg += 1;
  }
 
  return deg + '\u00b0 ' + ol.string.padNumber(min, 2) + '\u2032 ' +
    ol.string.padNumber(sec, 2, dflPrecision) + '\u2033 ' +
    hemispheres.charAt(normalizedDegrees < 0 ? 1 : 0);
};
 
 
/**
 * Transforms the given {@link ol.Coordinate} to a string using the given string
 * template. The strings `{x}` and `{y}` in the template will be replaced with
 * the first and second coordinate values respectively.
 *
 * Example without specifying the fractional digits:
 *
 *     var coord = [7.85, 47.983333];
 *     var template = 'Coordinate is ({x}|{y}).';
 *     var out = ol.coordinate.format(coord, template);
 *     // out is now 'Coordinate is (8|48).'
 *
 * Example explicitly specifying the fractional digits:
 *
 *     var coord = [7.85, 47.983333];
 *     var template = 'Coordinate is ({x}|{y}).';
 *     var out = ol.coordinate.format(coord, template, 2);
 *     // out is now 'Coordinate is (7.85|47.98).'
 *
 * @param {ol.Coordinate|undefined} coordinate Coordinate.
 * @param {string} template A template string with `{x}` and `{y}` placeholders
 *     that will be replaced by first and second coordinate values.
 * @param {number=} opt_fractionDigits The number of digits to include
 *    after the decimal point. Default is `0`.
 * @return {string} Formatted coordinate.
 * @api
 */
ol.coordinate.format = function(coordinate, template, opt_fractionDigits) {
  if (coordinate) {
    return template
      .replace('{x}', coordinate[0].toFixed(opt_fractionDigits))
      .replace('{y}', coordinate[1].toFixed(opt_fractionDigits));
  } else {
    return '';
  }
};
 
 
/**
 * @param {ol.Coordinate} coordinate1 First coordinate.
 * @param {ol.Coordinate} coordinate2 Second coordinate.
 * @return {boolean} Whether the passed coordinates are equal.
 */
ol.coordinate.equals = function(coordinate1, coordinate2) {
  var equals = true;
  for (var i = coordinate1.length - 1; i >= 0; --i) {
    if (coordinate1[i] != coordinate2[i]) {
      equals = false;
      break;
    }
  }
  return equals;
};
 
 
/**
 * Rotate `coordinate` by `angle`. `coordinate` is modified in place and
 * returned by the function.
 *
 * Example:
 *
 *     var coord = [7.85, 47.983333];
 *     var rotateRadians = Math.PI / 2; // 90 degrees
 *     ol.coordinate.rotate(coord, rotateRadians);
 *     // coord is now [-47.983333, 7.85]
 *
 * @param {ol.Coordinate} coordinate Coordinate.
 * @param {number} angle Angle in radian.
 * @return {ol.Coordinate} Coordinate.
 * @api
 */
ol.coordinate.rotate = function(coordinate, angle) {
  var cosAngle = Math.cos(angle);
  var sinAngle = Math.sin(angle);
  var x = coordinate[0] * cosAngle - coordinate[1] * sinAngle;
  var y = coordinate[1] * cosAngle + coordinate[0] * sinAngle;
  coordinate[0] = x;
  coordinate[1] = y;
  return coordinate;
};
 
 
/**
 * Scale `coordinate` by `scale`. `coordinate` is modified in place and returned
 * by the function.
 *
 * Example:
 *
 *     var coord = [7.85, 47.983333];
 *     var scale = 1.2;
 *     ol.coordinate.scale(coord, scale);
 *     // coord is now [9.42, 57.5799996]
 *
 * @param {ol.Coordinate} coordinate Coordinate.
 * @param {number} scale Scale factor.
 * @return {ol.Coordinate} Coordinate.
 */
ol.coordinate.scale = function(coordinate, scale) {
  coordinate[0] *= scale;
  coordinate[1] *= scale;
  return coordinate;
};
 
 
/**
 * Subtract `delta` to `coordinate`. `coordinate` is modified in place and
 * returned by the function.
 *
 * @param {ol.Coordinate} coordinate Coordinate.
 * @param {ol.Coordinate} delta Delta.
 * @return {ol.Coordinate} Coordinate.
 */
ol.coordinate.sub = function(coordinate, delta) {
  coordinate[0] -= delta[0];
  coordinate[1] -= delta[1];
  return coordinate;
};
 
 
/**
 * @param {ol.Coordinate} coord1 First coordinate.
 * @param {ol.Coordinate} coord2 Second coordinate.
 * @return {number} Squared distance between coord1 and coord2.
 */
ol.coordinate.squaredDistance = function(coord1, coord2) {
  var dx = coord1[0] - coord2[0];
  var dy = coord1[1] - coord2[1];
  return dx * dx + dy * dy;
};
 
 
/**
 * @param {ol.Coordinate} coord1 First coordinate.
 * @param {ol.Coordinate} coord2 Second coordinate.
 * @return {number} Distance between coord1 and coord2.
 */
ol.coordinate.distance = function(coord1, coord2) {
  return Math.sqrt(ol.coordinate.squaredDistance(coord1, coord2));
};
 
 
/**
 * Calculate the squared distance from a coordinate to a line segment.
 *
 * @param {ol.Coordinate} coordinate Coordinate of the point.
 * @param {Array.<ol.Coordinate>} segment Line segment (2 coordinates).
 * @return {number} Squared distance from the point to the line segment.
 */
ol.coordinate.squaredDistanceToSegment = function(coordinate, segment) {
  return ol.coordinate.squaredDistance(coordinate,
      ol.coordinate.closestOnSegment(coordinate, segment));
};
 
 
/**
 * Format a geographic coordinate with the hemisphere, degrees, minutes, and
 * seconds.
 *
 * Example without specifying fractional digits:
 *
 *     var coord = [7.85, 47.983333];
 *     var out = ol.coordinate.toStringHDMS(coord);
 *     // out is now '47° 58′ 60″ N 7° 50′ 60″ E'
 *
 * Example explicitly specifying 1 fractional digit:
 *
 *     var coord = [7.85, 47.983333];
 *     var out = ol.coordinate.toStringHDMS(coord, 1);
 *     // out is now '47° 58′ 60.0″ N 7° 50′ 60.0″ E'
 *
 * @param {ol.Coordinate|undefined} coordinate Coordinate.
 * @param {number=} opt_fractionDigits The number of digits to include
 *    after the decimal point. Default is `0`.
 * @return {string} Hemisphere, degrees, minutes and seconds.
 * @api
 */
ol.coordinate.toStringHDMS = function(coordinate, opt_fractionDigits) {
  if (coordinate) {
    return ol.coordinate.degreesToStringHDMS_(coordinate[1], 'NS', opt_fractionDigits) + ' ' +
        ol.coordinate.degreesToStringHDMS_(coordinate[0], 'EW', opt_fractionDigits);
  } else {
    return '';
  }
};
 
 
/**
 * Format a coordinate as a comma delimited string.
 *
 * Example without specifying fractional digits:
 *
 *     var coord = [7.85, 47.983333];
 *     var out = ol.coordinate.toStringXY(coord);
 *     // out is now '8, 48'
 *
 * Example explicitly specifying 1 fractional digit:
 *
 *     var coord = [7.85, 47.983333];
 *     var out = ol.coordinate.toStringXY(coord, 1);
 *     // out is now '7.8, 48.0'
 *
 * @param {ol.Coordinate|undefined} coordinate Coordinate.
 * @param {number=} opt_fractionDigits The number of digits to include
 *    after the decimal point. Default is `0`.
 * @return {string} XY.
 * @api
 */
ol.coordinate.toStringXY = function(coordinate, opt_fractionDigits) {
  return ol.coordinate.format(coordinate, '{x}, {y}', opt_fractionDigits);
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/css.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/css.js

Statements: 20% (1 / 5)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 20% (1 / 5)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 392                                                                            
goog.provide('ol.css');
 
 
/**
 * The CSS class for hidden feature.
 *
 * @const
 * @type {string}
 */
ol.css.CLASS_HIDDEN = 'ol-hidden';
 
 
/**
 * The CSS class that we'll give the DOM elements to have them unselectable.
 *
 * @const
 * @type {string}
 */
ol.css.CLASS_UNSELECTABLE = 'ol-unselectable';
 
 
/**
 * The CSS class for unsupported feature.
 *
 * @const
 * @type {string}
 */
ol.css.CLASS_UNSUPPORTED = 'ol-unsupported';
 
 
/**
 * The CSS class for controls.
 *
 * @const
 * @type {string}
 */
ol.css.CLASS_CONTROL = 'ol-control';
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/deviceorientation.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/deviceorientation.js

Statements: 1.92% (1 / 52)      Branches: 0% (0 / 28)      Functions: 0% (0 / 10)      Lines: 1.92% (1 / 52)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 2312                                                                                                                                                                                                                                                                                                                                                                                                                                                                            
goog.provide('ol.DeviceOrientation');
 
goog.require('ol.events');
goog.require('ol');
goog.require('ol.Object');
goog.require('ol.has');
goog.require('ol.math');
 
 
/**
 * @classdesc
 * The ol.DeviceOrientation class provides access to information from
 * DeviceOrientation events.  See the [HTML 5 DeviceOrientation Specification](
 * http://www.w3.org/TR/orientation-event/) for more details.
 *
 * Many new computers, and especially mobile phones
 * and tablets, provide hardware support for device orientation. Web
 * developers targeting mobile devices will be especially interested in this
 * class.
 *
 * Device orientation data are relative to a common starting point. For mobile
 * devices, the starting point is to lay your phone face up on a table with the
 * top of the phone pointing north. This represents the zero state. All
 * angles are then relative to this state. For computers, it is the same except
 * the screen is open at 90 degrees.
 *
 * Device orientation is reported as three angles - `alpha`, `beta`, and
 * `gamma` - relative to the starting position along the three planar axes X, Y
 * and Z. The X axis runs from the left edge to the right edge through the
 * middle of the device. Similarly, the Y axis runs from the bottom to the top
 * of the device through the middle. The Z axis runs from the back to the front
 * through the middle. In the starting position, the X axis points to the
 * right, the Y axis points away from you and the Z axis points straight up
 * from the device lying flat.
 *
 * The three angles representing the device orientation are relative to the
 * three axes. `alpha` indicates how much the device has been rotated around the
 * Z axis, which is commonly interpreted as the compass heading (see note
 * below). `beta` indicates how much the device has been rotated around the X
 * axis, or how much it is tilted from front to back.  `gamma` indicates how
 * much the device has been rotated around the Y axis, or how much it is tilted
 * from left to right.
 *
 * For most browsers, the `alpha` value returns the compass heading so if the
 * device points north, it will be 0.  With Safari on iOS, the 0 value of
 * `alpha` is calculated from when device orientation was first requested.
 * ol.DeviceOrientation provides the `heading` property which normalizes this
 * behavior across all browsers for you.
 *
 * It is important to note that the HTML 5 DeviceOrientation specification
 * indicates that `alpha`, `beta` and `gamma` are in degrees while the
 * equivalent properties in ol.DeviceOrientation are in radians for consistency
 * with all other uses of angles throughout OpenLayers.
 *
 * To get notified of device orientation changes, register a listener for the
 * generic `change` event on your `ol.DeviceOrientation` instance.
 *
 * @see {@link http://www.w3.org/TR/orientation-event/}
 *
 * @constructor
 * @extends {ol.Object}
 * @param {olx.DeviceOrientationOptions=} opt_options Options.
 * @api
 */
ol.DeviceOrientation = function(opt_options) {
 
  ol.Object.call(this);
 
  var options = opt_options ? opt_options : {};
 
  /**
   * @private
   * @type {?ol.EventsKey}
   */
  this.listenerKey_ = null;
 
  ol.events.listen(this,
      ol.Object.getChangeEventType(ol.DeviceOrientation.Property_.TRACKING),
      this.handleTrackingChanged_, this);
 
  this.setTracking(options.tracking !== undefined ? options.tracking : false);
 
};
ol.inherits(ol.DeviceOrientation, ol.Object);
 
 
/**
 * @inheritDoc
 */
ol.DeviceOrientation.prototype.disposeInternal = function() {
  this.setTracking(false);
  ol.Object.prototype.disposeInternal.call(this);
};
 
 
/**
 * @private
 * @param {Event} originalEvent Event.
 */
ol.DeviceOrientation.prototype.orientationChange_ = function(originalEvent) {
  var event = /** @type {DeviceOrientationEvent} */ (originalEvent);
  if (event.alpha !== null) {
    var alpha = ol.math.toRadians(event.alpha);
    this.set(ol.DeviceOrientation.Property_.ALPHA, alpha);
    // event.absolute is undefined in iOS.
    if (typeof event.absolute === 'boolean' && event.absolute) {
      this.set(ol.DeviceOrientation.Property_.HEADING, alpha);
    } else if (typeof event.webkitCompassHeading === 'number' &&
               event.webkitCompassAccuracy != -1) {
      var heading = ol.math.toRadians(event.webkitCompassHeading);
      this.set(ol.DeviceOrientation.Property_.HEADING, heading);
    }
  }
  if (event.beta !== null) {
    this.set(ol.DeviceOrientation.Property_.BETA,
        ol.math.toRadians(event.beta));
  }
  if (event.gamma !== null) {
    this.set(ol.DeviceOrientation.Property_.GAMMA,
        ol.math.toRadians(event.gamma));
  }
  this.changed();
};
 
 
/**
 * Rotation around the device z-axis (in radians).
 * @return {number|undefined} The euler angle in radians of the device from the
 *     standard Z axis.
 * @observable
 * @api
 */
ol.DeviceOrientation.prototype.getAlpha = function() {
  return /** @type {number|undefined} */ (
      this.get(ol.DeviceOrientation.Property_.ALPHA));
};
 
 
/**
 * Rotation around the device x-axis (in radians).
 * @return {number|undefined} The euler angle in radians of the device from the
 *     planar X axis.
 * @observable
 * @api
 */
ol.DeviceOrientation.prototype.getBeta = function() {
  return /** @type {number|undefined} */ (
      this.get(ol.DeviceOrientation.Property_.BETA));
};
 
 
/**
 * Rotation around the device y-axis (in radians).
 * @return {number|undefined} The euler angle in radians of the device from the
 *     planar Y axis.
 * @observable
 * @api
 */
ol.DeviceOrientation.prototype.getGamma = function() {
  return /** @type {number|undefined} */ (
      this.get(ol.DeviceOrientation.Property_.GAMMA));
};
 
 
/**
 * The heading of the device relative to north (in radians).
 * @return {number|undefined} The heading of the device relative to north, in
 *     radians, normalizing for different browser behavior.
 * @observable
 * @api
 */
ol.DeviceOrientation.prototype.getHeading = function() {
  return /** @type {number|undefined} */ (
      this.get(ol.DeviceOrientation.Property_.HEADING));
};
 
 
/**
 * Determine if orientation is being tracked.
 * @return {boolean} Changes in device orientation are being tracked.
 * @observable
 * @api
 */
ol.DeviceOrientation.prototype.getTracking = function() {
  return /** @type {boolean} */ (
      this.get(ol.DeviceOrientation.Property_.TRACKING));
};
 
 
/**
 * @private
 */
ol.DeviceOrientation.prototype.handleTrackingChanged_ = function() {
  if (ol.has.DEVICE_ORIENTATION) {
    var tracking = this.getTracking();
    if (tracking && !this.listenerKey_) {
      this.listenerKey_ = ol.events.listen(window, 'deviceorientation',
          this.orientationChange_, this);
    } else if (!tracking && this.listenerKey_ !== null) {
      ol.events.unlistenByKey(this.listenerKey_);
      this.listenerKey_ = null;
    }
  }
};
 
 
/**
 * Enable or disable tracking of device orientation events.
 * @param {boolean} tracking The status of tracking changes to alpha, beta and
 *     gamma. If true, changes are tracked and reported immediately.
 * @observable
 * @api
 */
ol.DeviceOrientation.prototype.setTracking = function(tracking) {
  this.set(ol.DeviceOrientation.Property_.TRACKING, tracking);
};
 
 
/**
 * @enum {string}
 * @private
 */
ol.DeviceOrientation.Property_ = {
  ALPHA: 'alpha',
  BETA: 'beta',
  GAMMA: 'gamma',
  HEADING: 'heading',
  TRACKING: 'tracking'
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/disposable.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/disposable.js

Statements: 11.11% (1 / 9)      Branches: 0% (0 / 2)      Functions: 0% (0 / 2)      Lines: 11.11% (1 / 9)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 342                                                                  
goog.provide('ol.Disposable');
 
goog.require('ol');
 
/**
 * Objects that need to clean up after themselves.
 * @constructor
 */
ol.Disposable = function() {};
 
/**
 * The object has already been disposed.
 * @type {boolean}
 * @private
 */
ol.Disposable.prototype.disposed_ = false;
 
/**
 * Clean up.
 */
ol.Disposable.prototype.dispose = function() {
  if (!this.disposed_) {
    this.disposed_ = true;
    this.disposeInternal();
  }
};
 
/**
 * Extension point for disposable objects.
 * @protected
 */
ol.Disposable.prototype.disposeInternal = ol.nullFunction;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/dom.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/dom.js

Statements: 3.7% (1 / 27)      Branches: 0% (0 / 10)      Functions: 0% (0 / 6)      Lines: 3.7% (1 / 27)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 812                                                                                                                                                                
goog.provide('ol.dom');
 
 
/**
 * Create an html canvas element and returns its 2d context.
 * @param {number=} opt_width Canvas width.
 * @param {number=} opt_height Canvas height.
 * @return {CanvasRenderingContext2D} The context.
 */
ol.dom.createCanvasContext2D = function(opt_width, opt_height) {
  var canvas = document.createElement('CANVAS');
  if (opt_width) {
    canvas.width = opt_width;
  }
  if (opt_height) {
    canvas.height = opt_height;
  }
  return canvas.getContext('2d');
};
 
 
/**
 * Get the current computed width for the given element including margin,
 * padding and border.
 * Equivalent to jQuery's `$(el).outerWidth(true)`.
 * @param {!Element} element Element.
 * @return {number} The width.
 */
ol.dom.outerWidth = function(element) {
  var width = element.offsetWidth;
  var style = getComputedStyle(element);
  width += parseInt(style.marginLeft, 10) + parseInt(style.marginRight, 10);
 
  return width;
};
 
 
/**
 * Get the current computed height for the given element including margin,
 * padding and border.
 * Equivalent to jQuery's `$(el).outerHeight(true)`.
 * @param {!Element} element Element.
 * @return {number} The height.
 */
ol.dom.outerHeight = function(element) {
  var height = element.offsetHeight;
  var style = getComputedStyle(element);
  height += parseInt(style.marginTop, 10) + parseInt(style.marginBottom, 10);
 
  return height;
};
 
/**
 * @param {Node} newNode Node to replace old node
 * @param {Node} oldNode The node to be replaced
 */
ol.dom.replaceNode = function(newNode, oldNode) {
  var parent = oldNode.parentNode;
  if (parent) {
    parent.replaceChild(newNode, oldNode);
  }
};
 
/**
 * @param {Node} node The node to remove.
 * @returns {Node} The node that was removed or null.
 */
ol.dom.removeNode = function(node) {
  return node && node.parentNode ? node.parentNode.removeChild(node) : null;
};
 
/**
 * @param {Node} node The node to remove the children from.
 */
ol.dom.removeChildren = function(node) {
  while (node.lastChild) {
    node.removeChild(node.lastChild);
  }
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/easing.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/easing.js

Statements: 7.69% (1 / 13)      Branches: 0% (0 / 2)      Functions: 0% (0 / 5)      Lines: 7.69% (1 / 13)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 642                                                                                                                              
goog.provide('ol.easing');
 
 
/**
 * Start slow and speed up.
 * @param {number} t Input between 0 and 1.
 * @return {number} Output between 0 and 1.
 * @api
 */
ol.easing.easeIn = function(t) {
  return Math.pow(t, 3);
};
 
 
/**
 * Start fast and slow down.
 * @param {number} t Input between 0 and 1.
 * @return {number} Output between 0 and 1.
 * @api
 */
ol.easing.easeOut = function(t) {
  return 1 - ol.easing.easeIn(1 - t);
};
 
 
/**
 * Start slow, speed up, and then slow down again.
 * @param {number} t Input between 0 and 1.
 * @return {number} Output between 0 and 1.
 * @api
 */
ol.easing.inAndOut = function(t) {
  return 3 * t * t - 2 * t * t * t;
};
 
 
/**
 * Maintain a constant speed over time.
 * @param {number} t Input between 0 and 1.
 * @return {number} Output between 0 and 1.
 * @api
 */
ol.easing.linear = function(t) {
  return t;
};
 
 
/**
 * Start slow, speed up, and at the very end slow down again.  This has the
 * same general behavior as {@link ol.easing.inAndOut}, but the final slowdown
 * is delayed.
 * @param {number} t Input between 0 and 1.
 * @return {number} Output between 0 and 1.
 * @api
 */
ol.easing.upAndDown = function(t) {
  if (t < 0.5) {
    return ol.easing.inAndOut(2 * t);
  } else {
    return 1 - ol.easing.inAndOut(2 * (t - 0.5));
  }
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/events.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/events.js

Statements: 1.32% (1 / 76)      Branches: 0% (0 / 42)      Functions: 0% (0 / 11)      Lines: 1.32% (1 / 76)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 2422                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  
goog.provide('ol.events');
 
goog.require('ol.obj');
 
 
/**
 * @param {ol.EventsKey} listenerObj Listener object.
 * @return {ol.EventsListenerFunctionType} Bound listener.
 */
ol.events.bindListener_ = function(listenerObj) {
  var boundListener = function(evt) {
    var listener = listenerObj.listener;
    var bindTo = listenerObj.bindTo || listenerObj.target;
    if (listenerObj.callOnce) {
      ol.events.unlistenByKey(listenerObj);
    }
    return listener.call(bindTo, evt);
  };
  listenerObj.boundListener = boundListener;
  return boundListener;
};
 
 
/**
 * Finds the matching {@link ol.EventsKey} in the given listener
 * array.
 *
 * @param {!Array<!ol.EventsKey>} listeners Array of listeners.
 * @param {!Function} listener The listener function.
 * @param {Object=} opt_this The `this` value inside the listener.
 * @param {boolean=} opt_setDeleteIndex Set the deleteIndex on the matching
 *     listener, for {@link ol.events.unlistenByKey}.
 * @return {ol.EventsKey|undefined} The matching listener object.
 * @private
 */
ol.events.findListener_ = function(listeners, listener, opt_this,
    opt_setDeleteIndex) {
  var listenerObj;
  for (var i = 0, ii = listeners.length; i < ii; ++i) {
    listenerObj = listeners[i];
    if (listenerObj.listener === listener &&
        listenerObj.bindTo === opt_this) {
      if (opt_setDeleteIndex) {
        listenerObj.deleteIndex = i;
      }
      return listenerObj;
    }
  }
  return undefined;
};
 
 
/**
 * @param {ol.EventTargetLike} target Target.
 * @param {string} type Type.
 * @return {Array.<ol.EventsKey>|undefined} Listeners.
 */
ol.events.getListeners = function(target, type) {
  var listenerMap = target.ol_lm;
  return listenerMap ? listenerMap[type] : undefined;
};
 
 
/**
 * Get the lookup of listeners.  If one does not exist on the target, it is
 * created.
 * @param {ol.EventTargetLike} target Target.
 * @return {!Object.<string, Array.<ol.EventsKey>>} Map of
 *     listeners by event type.
 * @private
 */
ol.events.getListenerMap_ = function(target) {
  var listenerMap = target.ol_lm;
  if (!listenerMap) {
    listenerMap = target.ol_lm = {};
  }
  return listenerMap;
};
 
 
/**
 * Clean up all listener objects of the given type.  All properties on the
 * listener objects will be removed, and if no listeners remain in the listener
 * map, it will be removed from the target.
 * @param {ol.EventTargetLike} target Target.
 * @param {string} type Type.
 * @private
 */
ol.events.removeListeners_ = function(target, type) {
  var listeners = ol.events.getListeners(target, type);
  if (listeners) {
    for (var i = 0, ii = listeners.length; i < ii; ++i) {
      target.removeEventListener(type, listeners[i].boundListener);
      ol.obj.clear(listeners[i]);
    }
    listeners.length = 0;
    var listenerMap = target.ol_lm;
    if (listenerMap) {
      delete listenerMap[type];
      if (Object.keys(listenerMap).length === 0) {
        delete target.ol_lm;
      }
    }
  }
};
 
 
/**
 * Registers an event listener on an event target. Inspired by
 * {@link https://google.github.io/closure-library/api/source/closure/goog/events/events.js.src.html}
 *
 * This function efficiently binds a `listener` to a `this` object, and returns
 * a key for use with {@link ol.events.unlistenByKey}.
 *
 * @param {ol.EventTargetLike} target Event target.
 * @param {string} type Event type.
 * @param {ol.EventsListenerFunctionType} listener Listener.
 * @param {Object=} opt_this Object referenced by the `this` keyword in the
 *     listener. Default is the `target`.
 * @param {boolean=} opt_once If true, add the listener as one-off listener.
 * @return {ol.EventsKey} Unique key for the listener.
 */
ol.events.listen = function(target, type, listener, opt_this, opt_once) {
  var listenerMap = ol.events.getListenerMap_(target);
  var listeners = listenerMap[type];
  if (!listeners) {
    listeners = listenerMap[type] = [];
  }
  var listenerObj = ol.events.findListener_(listeners, listener, opt_this,
      false);
  if (listenerObj) {
    if (!opt_once) {
      // Turn one-off listener into a permanent one.
      listenerObj.callOnce = false;
    }
  } else {
    listenerObj = /** @type {ol.EventsKey} */ ({
      bindTo: opt_this,
      callOnce: !!opt_once,
      listener: listener,
      target: target,
      type: type
    });
    target.addEventListener(type, ol.events.bindListener_(listenerObj));
    listeners.push(listenerObj);
  }
 
  return listenerObj;
};
 
 
/**
 * Registers a one-off event listener on an event target. Inspired by
 * {@link https://google.github.io/closure-library/api/source/closure/goog/events/events.js.src.html}
 *
 * This function efficiently binds a `listener` as self-unregistering listener
 * to a `this` object, and returns a key for use with
 * {@link ol.events.unlistenByKey} in case the listener needs to be unregistered
 * before it is called.
 *
 * When {@link ol.events.listen} is called with the same arguments after this
 * function, the self-unregistering listener will be turned into a permanent
 * listener.
 *
 * @param {ol.EventTargetLike} target Event target.
 * @param {string} type Event type.
 * @param {ol.EventsListenerFunctionType} listener Listener.
 * @param {Object=} opt_this Object referenced by the `this` keyword in the
 *     listener. Default is the `target`.
 * @return {ol.EventsKey} Key for unlistenByKey.
 */
ol.events.listenOnce = function(target, type, listener, opt_this) {
  return ol.events.listen(target, type, listener, opt_this, true);
};
 
 
/**
 * Unregisters an event listener on an event target. Inspired by
 * {@link https://google.github.io/closure-library/api/source/closure/goog/events/events.js.src.html}
 *
 * To return a listener, this function needs to be called with the exact same
 * arguments that were used for a previous {@link ol.events.listen} call.
 *
 * @param {ol.EventTargetLike} target Event target.
 * @param {string} type Event type.
 * @param {ol.EventsListenerFunctionType} listener Listener.
 * @param {Object=} opt_this Object referenced by the `this` keyword in the
 *     listener. Default is the `target`.
 */
ol.events.unlisten = function(target, type, listener, opt_this) {
  var listeners = ol.events.getListeners(target, type);
  if (listeners) {
    var listenerObj = ol.events.findListener_(listeners, listener, opt_this,
        true);
    if (listenerObj) {
      ol.events.unlistenByKey(listenerObj);
    }
  }
};
 
 
/**
 * Unregisters event listeners on an event target. Inspired by
 * {@link https://google.github.io/closure-library/api/source/closure/goog/events/events.js.src.html}
 *
 * The argument passed to this function is the key returned from
 * {@link ol.events.listen} or {@link ol.events.listenOnce}.
 *
 * @param {ol.EventsKey} key The key.
 */
ol.events.unlistenByKey = function(key) {
  if (key && key.target) {
    key.target.removeEventListener(key.type, key.boundListener);
    var listeners = ol.events.getListeners(key.target, key.type);
    if (listeners) {
      var i = 'deleteIndex' in key ? key.deleteIndex : listeners.indexOf(key);
      if (i !== -1) {
        listeners.splice(i, 1);
      }
      if (listeners.length === 0) {
        ol.events.removeListeners_(key.target, key.type);
      }
    }
    ol.obj.clear(key);
  }
};
 
 
/**
 * Unregisters all event listeners on an event target. Inspired by
 * {@link https://google.github.io/closure-library/api/source/closure/goog/events/events.js.src.html}
 *
 * @param {ol.EventTargetLike} target Target.
 */
ol.events.unlistenAll = function(target) {
  var listenerMap = ol.events.getListenerMap_(target);
  for (var type in listenerMap) {
    ol.events.removeListeners_(target, type);
  }
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/extent.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/extent.js

Statements: 0.35% (1 / 283)      Branches: 0% (0 / 121)      Functions: 0% (0 / 45)      Lines: 0.35% (1 / 283)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 7922                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              
goog.provide('ol.extent');
 
goog.require('ol.asserts');
goog.require('ol.extent.Corner');
goog.require('ol.extent.Relationship');
 
 
/**
 * Build an extent that includes all given coordinates.
 *
 * @param {Array.<ol.Coordinate>} coordinates Coordinates.
 * @return {ol.Extent} Bounding extent.
 * @api
 */
ol.extent.boundingExtent = function(coordinates) {
  var extent = ol.extent.createEmpty();
  for (var i = 0, ii = coordinates.length; i < ii; ++i) {
    ol.extent.extendCoordinate(extent, coordinates[i]);
  }
  return extent;
};
 
 
/**
 * @param {Array.<number>} xs Xs.
 * @param {Array.<number>} ys Ys.
 * @param {ol.Extent=} opt_extent Destination extent.
 * @private
 * @return {ol.Extent} Extent.
 */
ol.extent.boundingExtentXYs_ = function(xs, ys, opt_extent) {
  var minX = Math.min.apply(null, xs);
  var minY = Math.min.apply(null, ys);
  var maxX = Math.max.apply(null, xs);
  var maxY = Math.max.apply(null, ys);
  return ol.extent.createOrUpdate(minX, minY, maxX, maxY, opt_extent);
};
 
 
/**
 * Return extent increased by the provided value.
 * @param {ol.Extent} extent Extent.
 * @param {number} value The amount by which the extent should be buffered.
 * @param {ol.Extent=} opt_extent Extent.
 * @return {ol.Extent} Extent.
 * @api
 */
ol.extent.buffer = function(extent, value, opt_extent) {
  if (opt_extent) {
    opt_extent[0] = extent[0] - value;
    opt_extent[1] = extent[1] - value;
    opt_extent[2] = extent[2] + value;
    opt_extent[3] = extent[3] + value;
    return opt_extent;
  } else {
    return [
      extent[0] - value,
      extent[1] - value,
      extent[2] + value,
      extent[3] + value
    ];
  }
};
 
 
/**
 * Creates a clone of an extent.
 *
 * @param {ol.Extent} extent Extent to clone.
 * @param {ol.Extent=} opt_extent Extent.
 * @return {ol.Extent} The clone.
 */
ol.extent.clone = function(extent, opt_extent) {
  if (opt_extent) {
    opt_extent[0] = extent[0];
    opt_extent[1] = extent[1];
    opt_extent[2] = extent[2];
    opt_extent[3] = extent[3];
    return opt_extent;
  } else {
    return extent.slice();
  }
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @param {number} x X.
 * @param {number} y Y.
 * @return {number} Closest squared distance.
 */
ol.extent.closestSquaredDistanceXY = function(extent, x, y) {
  var dx, dy;
  if (x < extent[0]) {
    dx = extent[0] - x;
  } else if (extent[2] < x) {
    dx = x - extent[2];
  } else {
    dx = 0;
  }
  if (y < extent[1]) {
    dy = extent[1] - y;
  } else if (extent[3] < y) {
    dy = y - extent[3];
  } else {
    dy = 0;
  }
  return dx * dx + dy * dy;
};
 
 
/**
 * Check if the passed coordinate is contained or on the edge of the extent.
 *
 * @param {ol.Extent} extent Extent.
 * @param {ol.Coordinate} coordinate Coordinate.
 * @return {boolean} The coordinate is contained in the extent.
 * @api
 */
ol.extent.containsCoordinate = function(extent, coordinate) {
  return ol.extent.containsXY(extent, coordinate[0], coordinate[1]);
};
 
 
/**
 * Check if one extent contains another.
 *
 * An extent is deemed contained if it lies completely within the other extent,
 * including if they share one or more edges.
 *
 * @param {ol.Extent} extent1 Extent 1.
 * @param {ol.Extent} extent2 Extent 2.
 * @return {boolean} The second extent is contained by or on the edge of the
 *     first.
 * @api
 */
ol.extent.containsExtent = function(extent1, extent2) {
  return extent1[0] <= extent2[0] && extent2[2] <= extent1[2] &&
      extent1[1] <= extent2[1] && extent2[3] <= extent1[3];
};
 
 
/**
 * Check if the passed coordinate is contained or on the edge of the extent.
 *
 * @param {ol.Extent} extent Extent.
 * @param {number} x X coordinate.
 * @param {number} y Y coordinate.
 * @return {boolean} The x, y values are contained in the extent.
 * @api
 */
ol.extent.containsXY = function(extent, x, y) {
  return extent[0] <= x && x <= extent[2] && extent[1] <= y && y <= extent[3];
};
 
 
/**
 * Get the relationship between a coordinate and extent.
 * @param {ol.Extent} extent The extent.
 * @param {ol.Coordinate} coordinate The coordinate.
 * @return {number} The relationship (bitwise compare with
 *     ol.extent.Relationship).
 */
ol.extent.coordinateRelationship = function(extent, coordinate) {
  var minX = extent[0];
  var minY = extent[1];
  var maxX = extent[2];
  var maxY = extent[3];
  var x = coordinate[0];
  var y = coordinate[1];
  var relationship = ol.extent.Relationship.UNKNOWN;
  if (x < minX) {
    relationship = relationship | ol.extent.Relationship.LEFT;
  } else if (x > maxX) {
    relationship = relationship | ol.extent.Relationship.RIGHT;
  }
  if (y < minY) {
    relationship = relationship | ol.extent.Relationship.BELOW;
  } else if (y > maxY) {
    relationship = relationship | ol.extent.Relationship.ABOVE;
  }
  if (relationship === ol.extent.Relationship.UNKNOWN) {
    relationship = ol.extent.Relationship.INTERSECTING;
  }
  return relationship;
};
 
 
/**
 * Create an empty extent.
 * @return {ol.Extent} Empty extent.
 * @api
 */
ol.extent.createEmpty = function() {
  return [Infinity, Infinity, -Infinity, -Infinity];
};
 
 
/**
 * Create a new extent or update the provided extent.
 * @param {number} minX Minimum X.
 * @param {number} minY Minimum Y.
 * @param {number} maxX Maximum X.
 * @param {number} maxY Maximum Y.
 * @param {ol.Extent=} opt_extent Destination extent.
 * @return {ol.Extent} Extent.
 */
ol.extent.createOrUpdate = function(minX, minY, maxX, maxY, opt_extent) {
  if (opt_extent) {
    opt_extent[0] = minX;
    opt_extent[1] = minY;
    opt_extent[2] = maxX;
    opt_extent[3] = maxY;
    return opt_extent;
  } else {
    return [minX, minY, maxX, maxY];
  }
};
 
 
/**
 * Create a new empty extent or make the provided one empty.
 * @param {ol.Extent=} opt_extent Extent.
 * @return {ol.Extent} Extent.
 */
ol.extent.createOrUpdateEmpty = function(opt_extent) {
  return ol.extent.createOrUpdate(
      Infinity, Infinity, -Infinity, -Infinity, opt_extent);
};
 
 
/**
 * @param {ol.Coordinate} coordinate Coordinate.
 * @param {ol.Extent=} opt_extent Extent.
 * @return {ol.Extent} Extent.
 */
ol.extent.createOrUpdateFromCoordinate = function(coordinate, opt_extent) {
  var x = coordinate[0];
  var y = coordinate[1];
  return ol.extent.createOrUpdate(x, y, x, y, opt_extent);
};
 
 
/**
 * @param {Array.<ol.Coordinate>} coordinates Coordinates.
 * @param {ol.Extent=} opt_extent Extent.
 * @return {ol.Extent} Extent.
 */
ol.extent.createOrUpdateFromCoordinates = function(coordinates, opt_extent) {
  var extent = ol.extent.createOrUpdateEmpty(opt_extent);
  return ol.extent.extendCoordinates(extent, coordinates);
};
 
 
/**
 * @param {Array.<number>} flatCoordinates Flat coordinates.
 * @param {number} offset Offset.
 * @param {number} end End.
 * @param {number} stride Stride.
 * @param {ol.Extent=} opt_extent Extent.
 * @return {ol.Extent} Extent.
 */
ol.extent.createOrUpdateFromFlatCoordinates = function(flatCoordinates, offset, end, stride, opt_extent) {
  var extent = ol.extent.createOrUpdateEmpty(opt_extent);
  return ol.extent.extendFlatCoordinates(
      extent, flatCoordinates, offset, end, stride);
};
 
 
/**
 * @param {Array.<Array.<ol.Coordinate>>} rings Rings.
 * @param {ol.Extent=} opt_extent Extent.
 * @return {ol.Extent} Extent.
 */
ol.extent.createOrUpdateFromRings = function(rings, opt_extent) {
  var extent = ol.extent.createOrUpdateEmpty(opt_extent);
  return ol.extent.extendRings(extent, rings);
};
 
 
/**
 * Determine if two extents are equivalent.
 * @param {ol.Extent} extent1 Extent 1.
 * @param {ol.Extent} extent2 Extent 2.
 * @return {boolean} The two extents are equivalent.
 * @api
 */
ol.extent.equals = function(extent1, extent2) {
  return extent1[0] == extent2[0] && extent1[2] == extent2[2] &&
      extent1[1] == extent2[1] && extent1[3] == extent2[3];
};
 
 
/**
 * Modify an extent to include another extent.
 * @param {ol.Extent} extent1 The extent to be modified.
 * @param {ol.Extent} extent2 The extent that will be included in the first.
 * @return {ol.Extent} A reference to the first (extended) extent.
 * @api
 */
ol.extent.extend = function(extent1, extent2) {
  if (extent2[0] < extent1[0]) {
    extent1[0] = extent2[0];
  }
  if (extent2[2] > extent1[2]) {
    extent1[2] = extent2[2];
  }
  if (extent2[1] < extent1[1]) {
    extent1[1] = extent2[1];
  }
  if (extent2[3] > extent1[3]) {
    extent1[3] = extent2[3];
  }
  return extent1;
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @param {ol.Coordinate} coordinate Coordinate.
 */
ol.extent.extendCoordinate = function(extent, coordinate) {
  if (coordinate[0] < extent[0]) {
    extent[0] = coordinate[0];
  }
  if (coordinate[0] > extent[2]) {
    extent[2] = coordinate[0];
  }
  if (coordinate[1] < extent[1]) {
    extent[1] = coordinate[1];
  }
  if (coordinate[1] > extent[3]) {
    extent[3] = coordinate[1];
  }
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @param {Array.<ol.Coordinate>} coordinates Coordinates.
 * @return {ol.Extent} Extent.
 */
ol.extent.extendCoordinates = function(extent, coordinates) {
  var i, ii;
  for (i = 0, ii = coordinates.length; i < ii; ++i) {
    ol.extent.extendCoordinate(extent, coordinates[i]);
  }
  return extent;
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @param {Array.<number>} flatCoordinates Flat coordinates.
 * @param {number} offset Offset.
 * @param {number} end End.
 * @param {number} stride Stride.
 * @return {ol.Extent} Extent.
 */
ol.extent.extendFlatCoordinates = function(extent, flatCoordinates, offset, end, stride) {
  for (; offset < end; offset += stride) {
    ol.extent.extendXY(
        extent, flatCoordinates[offset], flatCoordinates[offset + 1]);
  }
  return extent;
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @param {Array.<Array.<ol.Coordinate>>} rings Rings.
 * @return {ol.Extent} Extent.
 */
ol.extent.extendRings = function(extent, rings) {
  var i, ii;
  for (i = 0, ii = rings.length; i < ii; ++i) {
    ol.extent.extendCoordinates(extent, rings[i]);
  }
  return extent;
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @param {number} x X.
 * @param {number} y Y.
 */
ol.extent.extendXY = function(extent, x, y) {
  extent[0] = Math.min(extent[0], x);
  extent[1] = Math.min(extent[1], y);
  extent[2] = Math.max(extent[2], x);
  extent[3] = Math.max(extent[3], y);
};
 
 
/**
 * This function calls `callback` for each corner of the extent. If the
 * callback returns a truthy value the function returns that value
 * immediately. Otherwise the function returns `false`.
 * @param {ol.Extent} extent Extent.
 * @param {function(this:T, ol.Coordinate): S} callback Callback.
 * @param {T=} opt_this Value to use as `this` when executing `callback`.
 * @return {S|boolean} Value.
 * @template S, T
 */
ol.extent.forEachCorner = function(extent, callback, opt_this) {
  var val;
  val = callback.call(opt_this, ol.extent.getBottomLeft(extent));
  if (val) {
    return val;
  }
  val = callback.call(opt_this, ol.extent.getBottomRight(extent));
  if (val) {
    return val;
  }
  val = callback.call(opt_this, ol.extent.getTopRight(extent));
  if (val) {
    return val;
  }
  val = callback.call(opt_this, ol.extent.getTopLeft(extent));
  if (val) {
    return val;
  }
  return false;
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @return {number} Area.
 */
ol.extent.getArea = function(extent) {
  var area = 0;
  if (!ol.extent.isEmpty(extent)) {
    area = ol.extent.getWidth(extent) * ol.extent.getHeight(extent);
  }
  return area;
};
 
 
/**
 * Get the bottom left coordinate of an extent.
 * @param {ol.Extent} extent Extent.
 * @return {ol.Coordinate} Bottom left coordinate.
 * @api
 */
ol.extent.getBottomLeft = function(extent) {
  return [extent[0], extent[1]];
};
 
 
/**
 * Get the bottom right coordinate of an extent.
 * @param {ol.Extent} extent Extent.
 * @return {ol.Coordinate} Bottom right coordinate.
 * @api
 */
ol.extent.getBottomRight = function(extent) {
  return [extent[2], extent[1]];
};
 
 
/**
 * Get the center coordinate of an extent.
 * @param {ol.Extent} extent Extent.
 * @return {ol.Coordinate} Center.
 * @api
 */
ol.extent.getCenter = function(extent) {
  return [(extent[0] + extent[2]) / 2, (extent[1] + extent[3]) / 2];
};
 
 
/**
 * Get a corner coordinate of an extent.
 * @param {ol.Extent} extent Extent.
 * @param {ol.extent.Corner} corner Corner.
 * @return {ol.Coordinate} Corner coordinate.
 */
ol.extent.getCorner = function(extent, corner) {
  var coordinate;
  if (corner === ol.extent.Corner.BOTTOM_LEFT) {
    coordinate = ol.extent.getBottomLeft(extent);
  } else if (corner === ol.extent.Corner.BOTTOM_RIGHT) {
    coordinate = ol.extent.getBottomRight(extent);
  } else if (corner === ol.extent.Corner.TOP_LEFT) {
    coordinate = ol.extent.getTopLeft(extent);
  } else if (corner === ol.extent.Corner.TOP_RIGHT) {
    coordinate = ol.extent.getTopRight(extent);
  } else {
    ol.asserts.assert(false, 13); // Invalid corner
  }
  return /** @type {!ol.Coordinate} */ (coordinate);
};
 
 
/**
 * @param {ol.Extent} extent1 Extent 1.
 * @param {ol.Extent} extent2 Extent 2.
 * @return {number} Enlarged area.
 */
ol.extent.getEnlargedArea = function(extent1, extent2) {
  var minX = Math.min(extent1[0], extent2[0]);
  var minY = Math.min(extent1[1], extent2[1]);
  var maxX = Math.max(extent1[2], extent2[2]);
  var maxY = Math.max(extent1[3], extent2[3]);
  return (maxX - minX) * (maxY - minY);
};
 
 
/**
 * @param {ol.Coordinate} center Center.
 * @param {number} resolution Resolution.
 * @param {number} rotation Rotation.
 * @param {ol.Size} size Size.
 * @param {ol.Extent=} opt_extent Destination extent.
 * @return {ol.Extent} Extent.
 */
ol.extent.getForViewAndSize = function(center, resolution, rotation, size, opt_extent) {
  var dx = resolution * size[0] / 2;
  var dy = resolution * size[1] / 2;
  var cosRotation = Math.cos(rotation);
  var sinRotation = Math.sin(rotation);
  var xCos = dx * cosRotation;
  var xSin = dx * sinRotation;
  var yCos = dy * cosRotation;
  var ySin = dy * sinRotation;
  var x = center[0];
  var y = center[1];
  var x0 = x - xCos + ySin;
  var x1 = x - xCos - ySin;
  var x2 = x + xCos - ySin;
  var x3 = x + xCos + ySin;
  var y0 = y - xSin - yCos;
  var y1 = y - xSin + yCos;
  var y2 = y + xSin + yCos;
  var y3 = y + xSin - yCos;
  return ol.extent.createOrUpdate(
      Math.min(x0, x1, x2, x3), Math.min(y0, y1, y2, y3),
      Math.max(x0, x1, x2, x3), Math.max(y0, y1, y2, y3),
      opt_extent);
};
 
 
/**
 * Get the height of an extent.
 * @param {ol.Extent} extent Extent.
 * @return {number} Height.
 * @api
 */
ol.extent.getHeight = function(extent) {
  return extent[3] - extent[1];
};
 
 
/**
 * @param {ol.Extent} extent1 Extent 1.
 * @param {ol.Extent} extent2 Extent 2.
 * @return {number} Intersection area.
 */
ol.extent.getIntersectionArea = function(extent1, extent2) {
  var intersection = ol.extent.getIntersection(extent1, extent2);
  return ol.extent.getArea(intersection);
};
 
 
/**
 * Get the intersection of two extents.
 * @param {ol.Extent} extent1 Extent 1.
 * @param {ol.Extent} extent2 Extent 2.
 * @param {ol.Extent=} opt_extent Optional extent to populate with intersection.
 * @return {ol.Extent} Intersecting extent.
 * @api
 */
ol.extent.getIntersection = function(extent1, extent2, opt_extent) {
  var intersection = opt_extent ? opt_extent : ol.extent.createEmpty();
  if (ol.extent.intersects(extent1, extent2)) {
    if (extent1[0] > extent2[0]) {
      intersection[0] = extent1[0];
    } else {
      intersection[0] = extent2[0];
    }
    if (extent1[1] > extent2[1]) {
      intersection[1] = extent1[1];
    } else {
      intersection[1] = extent2[1];
    }
    if (extent1[2] < extent2[2]) {
      intersection[2] = extent1[2];
    } else {
      intersection[2] = extent2[2];
    }
    if (extent1[3] < extent2[3]) {
      intersection[3] = extent1[3];
    } else {
      intersection[3] = extent2[3];
    }
  }
  return intersection;
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @return {number} Margin.
 */
ol.extent.getMargin = function(extent) {
  return ol.extent.getWidth(extent) + ol.extent.getHeight(extent);
};
 
 
/**
 * Get the size (width, height) of an extent.
 * @param {ol.Extent} extent The extent.
 * @return {ol.Size} The extent size.
 * @api
 */
ol.extent.getSize = function(extent) {
  return [extent[2] - extent[0], extent[3] - extent[1]];
};
 
 
/**
 * Get the top left coordinate of an extent.
 * @param {ol.Extent} extent Extent.
 * @return {ol.Coordinate} Top left coordinate.
 * @api
 */
ol.extent.getTopLeft = function(extent) {
  return [extent[0], extent[3]];
};
 
 
/**
 * Get the top right coordinate of an extent.
 * @param {ol.Extent} extent Extent.
 * @return {ol.Coordinate} Top right coordinate.
 * @api
 */
ol.extent.getTopRight = function(extent) {
  return [extent[2], extent[3]];
};
 
 
/**
 * Get the width of an extent.
 * @param {ol.Extent} extent Extent.
 * @return {number} Width.
 * @api
 */
ol.extent.getWidth = function(extent) {
  return extent[2] - extent[0];
};
 
 
/**
 * Determine if one extent intersects another.
 * @param {ol.Extent} extent1 Extent 1.
 * @param {ol.Extent} extent2 Extent.
 * @return {boolean} The two extents intersect.
 * @api
 */
ol.extent.intersects = function(extent1, extent2) {
  return extent1[0] <= extent2[2] &&
      extent1[2] >= extent2[0] &&
      extent1[1] <= extent2[3] &&
      extent1[3] >= extent2[1];
};
 
 
/**
 * Determine if an extent is empty.
 * @param {ol.Extent} extent Extent.
 * @return {boolean} Is empty.
 * @api
 */
ol.extent.isEmpty = function(extent) {
  return extent[2] < extent[0] || extent[3] < extent[1];
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @param {ol.Extent=} opt_extent Extent.
 * @return {ol.Extent} Extent.
 */
ol.extent.returnOrUpdate = function(extent, opt_extent) {
  if (opt_extent) {
    opt_extent[0] = extent[0];
    opt_extent[1] = extent[1];
    opt_extent[2] = extent[2];
    opt_extent[3] = extent[3];
    return opt_extent;
  } else {
    return extent;
  }
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @param {number} value Value.
 */
ol.extent.scaleFromCenter = function(extent, value) {
  var deltaX = ((extent[2] - extent[0]) / 2) * (value - 1);
  var deltaY = ((extent[3] - extent[1]) / 2) * (value - 1);
  extent[0] -= deltaX;
  extent[2] += deltaX;
  extent[1] -= deltaY;
  extent[3] += deltaY;
};
 
 
/**
 * Determine if the segment between two coordinates intersects (crosses,
 * touches, or is contained by) the provided extent.
 * @param {ol.Extent} extent The extent.
 * @param {ol.Coordinate} start Segment start coordinate.
 * @param {ol.Coordinate} end Segment end coordinate.
 * @return {boolean} The segment intersects the extent.
 */
ol.extent.intersectsSegment = function(extent, start, end) {
  var intersects = false;
  var startRel = ol.extent.coordinateRelationship(extent, start);
  var endRel = ol.extent.coordinateRelationship(extent, end);
  if (startRel === ol.extent.Relationship.INTERSECTING ||
      endRel === ol.extent.Relationship.INTERSECTING) {
    intersects = true;
  } else {
    var minX = extent[0];
    var minY = extent[1];
    var maxX = extent[2];
    var maxY = extent[3];
    var startX = start[0];
    var startY = start[1];
    var endX = end[0];
    var endY = end[1];
    var slope = (endY - startY) / (endX - startX);
    var x, y;
    if (!!(endRel & ol.extent.Relationship.ABOVE) &&
        !(startRel & ol.extent.Relationship.ABOVE)) {
      // potentially intersects top
      x = endX - ((endY - maxY) / slope);
      intersects = x >= minX && x <= maxX;
    }
    if (!intersects && !!(endRel & ol.extent.Relationship.RIGHT) &&
        !(startRel & ol.extent.Relationship.RIGHT)) {
      // potentially intersects right
      y = endY - ((endX - maxX) * slope);
      intersects = y >= minY && y <= maxY;
    }
    if (!intersects && !!(endRel & ol.extent.Relationship.BELOW) &&
        !(startRel & ol.extent.Relationship.BELOW)) {
      // potentially intersects bottom
      x = endX - ((endY - minY) / slope);
      intersects = x >= minX && x <= maxX;
    }
    if (!intersects && !!(endRel & ol.extent.Relationship.LEFT) &&
        !(startRel & ol.extent.Relationship.LEFT)) {
      // potentially intersects left
      y = endY - ((endX - minX) * slope);
      intersects = y >= minY && y <= maxY;
    }
 
  }
  return intersects;
};
 
 
/**
 * Apply a transform function to the extent.
 * @param {ol.Extent} extent Extent.
 * @param {ol.TransformFunction} transformFn Transform function.  Called with
 * [minX, minY, maxX, maxY] extent coordinates.
 * @param {ol.Extent=} opt_extent Destination extent.
 * @return {ol.Extent} Extent.
 * @api
 */
ol.extent.applyTransform = function(extent, transformFn, opt_extent) {
  var coordinates = [
    extent[0], extent[1],
    extent[0], extent[3],
    extent[2], extent[1],
    extent[2], extent[3]
  ];
  transformFn(coordinates, coordinates, 2);
  var xs = [coordinates[0], coordinates[2], coordinates[4], coordinates[6]];
  var ys = [coordinates[1], coordinates[3], coordinates[5], coordinates[7]];
  return ol.extent.boundingExtentXYs_(xs, ys, opt_extent);
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/feature.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/feature.js

Statements: 1.22% (1 / 82)      Branches: 0% (0 / 22)      Functions: 0% (0 / 16)      Lines: 1.22% (1 / 82)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 3202                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              
goog.provide('ol.Feature');
 
goog.require('ol.asserts');
goog.require('ol.events');
goog.require('ol.events.EventType');
goog.require('ol');
goog.require('ol.Object');
goog.require('ol.geom.Geometry');
goog.require('ol.style.Style');
 
 
/**
 * @classdesc
 * A vector object for geographic features with a geometry and other
 * attribute properties, similar to the features in vector file formats like
 * GeoJSON.
 *
 * Features can be styled individually with `setStyle`; otherwise they use the
 * style of their vector layer.
 *
 * Note that attribute properties are set as {@link ol.Object} properties on
 * the feature object, so they are observable, and have get/set accessors.
 *
 * Typically, a feature has a single geometry property. You can set the
 * geometry using the `setGeometry` method and get it with `getGeometry`.
 * It is possible to store more than one geometry on a feature using attribute
 * properties. By default, the geometry used for rendering is identified by
 * the property name `geometry`. If you want to use another geometry property
 * for rendering, use the `setGeometryName` method to change the attribute
 * property associated with the geometry for the feature.  For example:
 *
 * ```js
 * var feature = new ol.Feature({
 *   geometry: new ol.geom.Polygon(polyCoords),
 *   labelPoint: new ol.geom.Point(labelCoords),
 *   name: 'My Polygon'
 * });
 *
 * // get the polygon geometry
 * var poly = feature.getGeometry();
 *
 * // Render the feature as a point using the coordinates from labelPoint
 * feature.setGeometryName('labelPoint');
 *
 * // get the point geometry
 * var point = feature.getGeometry();
 * ```
 *
 * @constructor
 * @extends {ol.Object}
 * @param {ol.geom.Geometry|Object.<string, *>=} opt_geometryOrProperties
 *     You may pass a Geometry object directly, or an object literal
 *     containing properties.  If you pass an object literal, you may
 *     include a Geometry associated with a `geometry` key.
 * @api
 */
ol.Feature = function(opt_geometryOrProperties) {
 
  ol.Object.call(this);
 
  /**
   * @private
   * @type {number|string|undefined}
   */
  this.id_ = undefined;
 
  /**
   * @type {string}
   * @private
   */
  this.geometryName_ = 'geometry';
 
  /**
   * User provided style.
   * @private
   * @type {ol.style.Style|Array.<ol.style.Style>|
   *     ol.FeatureStyleFunction}
   */
  this.style_ = null;
 
  /**
   * @private
   * @type {ol.FeatureStyleFunction|undefined}
   */
  this.styleFunction_ = undefined;
 
  /**
   * @private
   * @type {?ol.EventsKey}
   */
  this.geometryChangeKey_ = null;
 
  ol.events.listen(
      this, ol.Object.getChangeEventType(this.geometryName_),
      this.handleGeometryChanged_, this);
 
  if (opt_geometryOrProperties !== undefined) {
    if (opt_geometryOrProperties instanceof ol.geom.Geometry ||
        !opt_geometryOrProperties) {
      var geometry = opt_geometryOrProperties;
      this.setGeometry(geometry);
    } else {
      /** @type {Object.<string, *>} */
      var properties = opt_geometryOrProperties;
      this.setProperties(properties);
    }
  }
};
ol.inherits(ol.Feature, ol.Object);
 
 
/**
 * Clone this feature. If the original feature has a geometry it
 * is also cloned. The feature id is not set in the clone.
 * @return {ol.Feature} The clone.
 * @api
 */
ol.Feature.prototype.clone = function() {
  var clone = new ol.Feature(this.getProperties());
  clone.setGeometryName(this.getGeometryName());
  var geometry = this.getGeometry();
  if (geometry) {
    clone.setGeometry(geometry.clone());
  }
  var style = this.getStyle();
  if (style) {
    clone.setStyle(style);
  }
  return clone;
};
 
 
/**
 * Get the feature's default geometry.  A feature may have any number of named
 * geometries.  The "default" geometry (the one that is rendered by default) is
 * set when calling {@link ol.Feature#setGeometry}.
 * @return {ol.geom.Geometry|undefined} The default geometry for the feature.
 * @api
 * @observable
 */
ol.Feature.prototype.getGeometry = function() {
  return /** @type {ol.geom.Geometry|undefined} */ (
      this.get(this.geometryName_));
};
 
 
/**
 * Get the feature identifier.  This is a stable identifier for the feature and
 * is either set when reading data from a remote source or set explicitly by
 * calling {@link ol.Feature#setId}.
 * @return {number|string|undefined} Id.
 * @api
 */
ol.Feature.prototype.getId = function() {
  return this.id_;
};
 
 
/**
 * Get the name of the feature's default geometry.  By default, the default
 * geometry is named `geometry`.
 * @return {string} Get the property name associated with the default geometry
 *     for this feature.
 * @api
 */
ol.Feature.prototype.getGeometryName = function() {
  return this.geometryName_;
};
 
 
/**
 * Get the feature's style. Will return what was provided to the
 * {@link ol.Feature#setStyle} method.
 * @return {ol.style.Style|Array.<ol.style.Style>|
 *     ol.FeatureStyleFunction|ol.StyleFunction} The feature style.
 * @api
 */
ol.Feature.prototype.getStyle = function() {
  return this.style_;
};
 
 
/**
 * Get the feature's style function.
 * @return {ol.FeatureStyleFunction|undefined} Return a function
 * representing the current style of this feature.
 * @api
 */
ol.Feature.prototype.getStyleFunction = function() {
  return this.styleFunction_;
};
 
 
/**
 * @private
 */
ol.Feature.prototype.handleGeometryChange_ = function() {
  this.changed();
};
 
 
/**
 * @private
 */
ol.Feature.prototype.handleGeometryChanged_ = function() {
  if (this.geometryChangeKey_) {
    ol.events.unlistenByKey(this.geometryChangeKey_);
    this.geometryChangeKey_ = null;
  }
  var geometry = this.getGeometry();
  if (geometry) {
    this.geometryChangeKey_ = ol.events.listen(geometry,
        ol.events.EventType.CHANGE, this.handleGeometryChange_, this);
  }
  this.changed();
};
 
 
/**
 * Set the default geometry for the feature.  This will update the property
 * with the name returned by {@link ol.Feature#getGeometryName}.
 * @param {ol.geom.Geometry|undefined} geometry The new geometry.
 * @api
 * @observable
 */
ol.Feature.prototype.setGeometry = function(geometry) {
  this.set(this.geometryName_, geometry);
};
 
 
/**
 * Set the style for the feature.  This can be a single style object, an array
 * of styles, or a function that takes a resolution and returns an array of
 * styles. If it is `null` the feature has no style (a `null` style).
 * @param {ol.style.Style|Array.<ol.style.Style>|
 *     ol.FeatureStyleFunction|ol.StyleFunction} style Style for this feature.
 * @api
 * @fires ol.events.Event#event:change
 */
ol.Feature.prototype.setStyle = function(style) {
  this.style_ = style;
  this.styleFunction_ = !style ?
      undefined : ol.Feature.createStyleFunction(style);
  this.changed();
};
 
 
/**
 * Set the feature id.  The feature id is considered stable and may be used when
 * requesting features or comparing identifiers returned from a remote source.
 * The feature id can be used with the {@link ol.source.Vector#getFeatureById}
 * method.
 * @param {number|string|undefined} id The feature id.
 * @api
 * @fires ol.events.Event#event:change
 */
ol.Feature.prototype.setId = function(id) {
  this.id_ = id;
  this.changed();
};
 
 
/**
 * Set the property name to be used when getting the feature's default geometry.
 * When calling {@link ol.Feature#getGeometry}, the value of the property with
 * this name will be returned.
 * @param {string} name The property name of the default geometry.
 * @api
 */
ol.Feature.prototype.setGeometryName = function(name) {
  ol.events.unlisten(
      this, ol.Object.getChangeEventType(this.geometryName_),
      this.handleGeometryChanged_, this);
  this.geometryName_ = name;
  ol.events.listen(
      this, ol.Object.getChangeEventType(this.geometryName_),
      this.handleGeometryChanged_, this);
  this.handleGeometryChanged_();
};
 
 
/**
 * Convert the provided object into a feature style function.  Functions passed
 * through unchanged.  Arrays of ol.style.Style or single style objects wrapped
 * in a new feature style function.
 * @param {ol.FeatureStyleFunction|!Array.<ol.style.Style>|!ol.style.Style} obj
 *     A feature style function, a single style, or an array of styles.
 * @return {ol.FeatureStyleFunction} A style function.
 */
ol.Feature.createStyleFunction = function(obj) {
  var styleFunction;
 
  if (typeof obj === 'function') {
    if (obj.length == 2) {
      styleFunction = function(resolution) {
        return /** @type {ol.StyleFunction} */ (obj)(this, resolution);
      };
    } else {
      styleFunction = obj;
    }
  } else {
    /**
     * @type {Array.<ol.style.Style>}
     */
    var styles;
    if (Array.isArray(obj)) {
      styles = obj;
    } else {
      ol.asserts.assert(obj instanceof ol.style.Style,
          41); // Expected an `ol.style.Style` or an array of `ol.style.Style`
      styles = [obj];
    }
    styleFunction = function() {
      return styles;
    };
  }
  return styleFunction;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/featureloader.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/featureloader.js

Statements: 3.13% (1 / 32)      Branches: 0% (0 / 21)      Functions: 0% (0 / 6)      Lines: 3.13% (1 / 32)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 992                                                                                                                                                                                                    
goog.provide('ol.featureloader');
 
goog.require('ol');
goog.require('ol.format.FormatType');
goog.require('ol.xml');
 
 
/**
 * @param {string|ol.FeatureUrlFunction} url Feature URL service.
 * @param {ol.format.Feature} format Feature format.
 * @param {function(this:ol.VectorTile, Array.<ol.Feature>, ol.proj.Projection)|function(this:ol.source.Vector, Array.<ol.Feature>)} success
 *     Function called with the loaded features and optionally with the data
 *     projection. Called with the vector tile or source as `this`.
 * @param {function(this:ol.VectorTile)|function(this:ol.source.Vector)} failure
 *     Function called when loading failed. Called with the vector tile or
 *     source as `this`.
 * @return {ol.FeatureLoader} The feature loader.
 */
ol.featureloader.loadFeaturesXhr = function(url, format, success, failure) {
  return (
      /**
       * @param {ol.Extent} extent Extent.
       * @param {number} resolution Resolution.
       * @param {ol.proj.Projection} projection Projection.
       * @this {ol.source.Vector|ol.VectorTile}
       */
      function(extent, resolution, projection) {
        var xhr = new XMLHttpRequest();
        xhr.open('GET',
            typeof url === 'function' ? url(extent, resolution, projection) : url,
            true);
        if (format.getType() == ol.format.FormatType.ARRAY_BUFFER) {
          xhr.responseType = 'arraybuffer';
        }
        /**
         * @param {Event} event Event.
         * @private
         */
        xhr.onload = function(event) {
          // status will be 0 for file:// urls
          if (!xhr.status || xhr.status >= 200 && xhr.status < 300) {
            var type = format.getType();
            /** @type {Document|Node|Object|string|undefined} */
            var source;
            if (type == ol.format.FormatType.JSON ||
                type == ol.format.FormatType.TEXT) {
              source = xhr.responseText;
            } else if (type == ol.format.FormatType.XML) {
              source = xhr.responseXML;
              if (!source) {
                source = ol.xml.parse(xhr.responseText);
              }
            } else if (type == ol.format.FormatType.ARRAY_BUFFER) {
              source = /** @type {ArrayBuffer} */ (xhr.response);
            }
            if (source) {
              success.call(this, format.readFeatures(source,
                  {featureProjection: projection}),
                  format.readProjection(source));
            } else {
              failure.call(this);
            }
          } else {
            failure.call(this);
          }
        }.bind(this);
        /**
         * @private
         */
        xhr.onerror = function() {
          failure.call(this);
        }.bind(this);
        xhr.send();
      });
};
 
 
/**
 * Create an XHR feature loader for a `url` and `format`. The feature loader
 * loads features (with XHR), parses the features, and adds them to the
 * vector source.
 * @param {string|ol.FeatureUrlFunction} url Feature URL service.
 * @param {ol.format.Feature} format Feature format.
 * @return {ol.FeatureLoader} The feature loader.
 * @api
 */
ol.featureloader.xhr = function(url, format) {
  return ol.featureloader.loadFeaturesXhr(url, format,
      /**
       * @param {Array.<ol.Feature>} features The loaded features.
       * @param {ol.proj.Projection} dataProjection Data projection.
       * @this {ol.source.Vector}
       */
      function(features, dataProjection) {
        this.addFeatures(features);
      }, /* FIXME handle error */ ol.nullFunction);
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/functions.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/functions.js

Statements: 20% (1 / 5)      Branches: 100% (0 / 0)      Functions: 0% (0 / 2)      Lines: 20% (1 / 5)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 192                                    
goog.provide('ol.functions');
 
/**
 * Always returns true.
 * @returns {boolean} true.
 */
ol.functions.TRUE = function() {
  return true;
};
 
/**
 * Always returns false.
 * @returns {boolean} false.
 */
ol.functions.FALSE = function() {
  return false;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/geolocation.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/geolocation.js

Statements: 1.12% (1 / 89)      Branches: 0% (0 / 34)      Functions: 0% (0 / 19)      Lines: 1.12% (1 / 89)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345    2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            
// FIXME handle geolocation not supported
 
goog.provide('ol.Geolocation');
 
goog.require('ol');
goog.require('ol.Object');
goog.require('ol.GeolocationProperty');
goog.require('ol.events');
goog.require('ol.events.EventType');
goog.require('ol.geom.Polygon');
goog.require('ol.has');
goog.require('ol.math');
goog.require('ol.proj');
goog.require('ol.sphere.WGS84');
 
 
/**
 * @classdesc
 * Helper class for providing HTML5 Geolocation capabilities.
 * The [Geolocation API](http://www.w3.org/TR/geolocation-API/)
 * is used to locate a user's position.
 *
 * To get notified of position changes, register a listener for the generic
 * `change` event on your instance of `ol.Geolocation`.
 *
 * Example:
 *
 *     var geolocation = new ol.Geolocation({
 *       // take the projection to use from the map's view
 *       projection: view.getProjection()
 *     });
 *     // listen to changes in position
 *     geolocation.on('change', function(evt) {
 *       window.console.log(geolocation.getPosition());
 *     });
 *
 * @fires error
 * @constructor
 * @extends {ol.Object}
 * @param {olx.GeolocationOptions=} opt_options Options.
 * @api
 */
ol.Geolocation = function(opt_options) {
 
  ol.Object.call(this);
 
  var options = opt_options || {};
 
  /**
   * The unprojected (EPSG:4326) device position.
   * @private
   * @type {ol.Coordinate}
   */
  this.position_ = null;
 
  /**
   * @private
   * @type {ol.TransformFunction}
   */
  this.transform_ = ol.proj.identityTransform;
 
  /**
   * @private
   * @type {number|undefined}
   */
  this.watchId_ = undefined;
 
  ol.events.listen(
      this, ol.Object.getChangeEventType(ol.GeolocationProperty.PROJECTION),
      this.handleProjectionChanged_, this);
  ol.events.listen(
      this, ol.Object.getChangeEventType(ol.GeolocationProperty.TRACKING),
      this.handleTrackingChanged_, this);
 
  if (options.projection !== undefined) {
    this.setProjection(ol.proj.get(options.projection));
  }
  if (options.trackingOptions !== undefined) {
    this.setTrackingOptions(options.trackingOptions);
  }
 
  this.setTracking(options.tracking !== undefined ? options.tracking : false);
 
};
ol.inherits(ol.Geolocation, ol.Object);
 
 
/**
 * @inheritDoc
 */
ol.Geolocation.prototype.disposeInternal = function() {
  this.setTracking(false);
  ol.Object.prototype.disposeInternal.call(this);
};
 
 
/**
 * @private
 */
ol.Geolocation.prototype.handleProjectionChanged_ = function() {
  var projection = this.getProjection();
  if (projection) {
    this.transform_ = ol.proj.getTransformFromProjections(
        ol.proj.get('EPSG:4326'), projection);
    if (this.position_) {
      this.set(
          ol.GeolocationProperty.POSITION, this.transform_(this.position_));
    }
  }
};
 
 
/**
 * @private
 */
ol.Geolocation.prototype.handleTrackingChanged_ = function() {
  if (ol.has.GEOLOCATION) {
    var tracking = this.getTracking();
    if (tracking && this.watchId_ === undefined) {
      this.watchId_ = navigator.geolocation.watchPosition(
          this.positionChange_.bind(this),
          this.positionError_.bind(this),
          this.getTrackingOptions());
    } else if (!tracking && this.watchId_ !== undefined) {
      navigator.geolocation.clearWatch(this.watchId_);
      this.watchId_ = undefined;
    }
  }
};
 
 
/**
 * @private
 * @param {GeolocationPosition} position position event.
 */
ol.Geolocation.prototype.positionChange_ = function(position) {
  var coords = position.coords;
  this.set(ol.GeolocationProperty.ACCURACY, coords.accuracy);
  this.set(ol.GeolocationProperty.ALTITUDE,
      coords.altitude === null ? undefined : coords.altitude);
  this.set(ol.GeolocationProperty.ALTITUDE_ACCURACY,
      coords.altitudeAccuracy === null ?
      undefined : coords.altitudeAccuracy);
  this.set(ol.GeolocationProperty.HEADING, coords.heading === null ?
      undefined : ol.math.toRadians(coords.heading));
  if (!this.position_) {
    this.position_ = [coords.longitude, coords.latitude];
  } else {
    this.position_[0] = coords.longitude;
    this.position_[1] = coords.latitude;
  }
  var projectedPosition = this.transform_(this.position_);
  this.set(ol.GeolocationProperty.POSITION, projectedPosition);
  this.set(ol.GeolocationProperty.SPEED,
      coords.speed === null ? undefined : coords.speed);
  var geometry = ol.geom.Polygon.circular(
      ol.sphere.WGS84, this.position_, coords.accuracy);
  geometry.applyTransform(this.transform_);
  this.set(ol.GeolocationProperty.ACCURACY_GEOMETRY, geometry);
  this.changed();
};
 
/**
 * Triggered when the Geolocation returns an error.
 * @event error
 * @api
 */
 
/**
 * @private
 * @param {GeolocationPositionError} error error object.
 */
ol.Geolocation.prototype.positionError_ = function(error) {
  error.type = ol.events.EventType.ERROR;
  this.setTracking(false);
  this.dispatchEvent(/** @type {{type: string, target: undefined}} */ (error));
};
 
 
/**
 * Get the accuracy of the position in meters.
 * @return {number|undefined} The accuracy of the position measurement in
 *     meters.
 * @observable
 * @api
 */
ol.Geolocation.prototype.getAccuracy = function() {
  return /** @type {number|undefined} */ (
      this.get(ol.GeolocationProperty.ACCURACY));
};
 
 
/**
 * Get a geometry of the position accuracy.
 * @return {?ol.geom.Polygon} A geometry of the position accuracy.
 * @observable
 * @api
 */
ol.Geolocation.prototype.getAccuracyGeometry = function() {
  return /** @type {?ol.geom.Polygon} */ (
      this.get(ol.GeolocationProperty.ACCURACY_GEOMETRY) || null);
};
 
 
/**
 * Get the altitude associated with the position.
 * @return {number|undefined} The altitude of the position in meters above mean
 *     sea level.
 * @observable
 * @api
 */
ol.Geolocation.prototype.getAltitude = function() {
  return /** @type {number|undefined} */ (
      this.get(ol.GeolocationProperty.ALTITUDE));
};
 
 
/**
 * Get the altitude accuracy of the position.
 * @return {number|undefined} The accuracy of the altitude measurement in
 *     meters.
 * @observable
 * @api
 */
ol.Geolocation.prototype.getAltitudeAccuracy = function() {
  return /** @type {number|undefined} */ (
      this.get(ol.GeolocationProperty.ALTITUDE_ACCURACY));
};
 
 
/**
 * Get the heading as radians clockwise from North.
 * @return {number|undefined} The heading of the device in radians from north.
 * @observable
 * @api
 */
ol.Geolocation.prototype.getHeading = function() {
  return /** @type {number|undefined} */ (
      this.get(ol.GeolocationProperty.HEADING));
};
 
 
/**
 * Get the position of the device.
 * @return {ol.Coordinate|undefined} The current position of the device reported
 *     in the current projection.
 * @observable
 * @api
 */
ol.Geolocation.prototype.getPosition = function() {
  return /** @type {ol.Coordinate|undefined} */ (
      this.get(ol.GeolocationProperty.POSITION));
};
 
 
/**
 * Get the projection associated with the position.
 * @return {ol.proj.Projection|undefined} The projection the position is
 *     reported in.
 * @observable
 * @api
 */
ol.Geolocation.prototype.getProjection = function() {
  return /** @type {ol.proj.Projection|undefined} */ (
      this.get(ol.GeolocationProperty.PROJECTION));
};
 
 
/**
 * Get the speed in meters per second.
 * @return {number|undefined} The instantaneous speed of the device in meters
 *     per second.
 * @observable
 * @api
 */
ol.Geolocation.prototype.getSpeed = function() {
  return /** @type {number|undefined} */ (
      this.get(ol.GeolocationProperty.SPEED));
};
 
 
/**
 * Determine if the device location is being tracked.
 * @return {boolean} The device location is being tracked.
 * @observable
 * @api
 */
ol.Geolocation.prototype.getTracking = function() {
  return /** @type {boolean} */ (
      this.get(ol.GeolocationProperty.TRACKING));
};
 
 
/**
 * Get the tracking options.
 * @see http://www.w3.org/TR/geolocation-API/#position-options
 * @return {GeolocationPositionOptions|undefined} PositionOptions as defined by
 *     the [HTML5 Geolocation spec
 *     ](http://www.w3.org/TR/geolocation-API/#position_options_interface).
 * @observable
 * @api
 */
ol.Geolocation.prototype.getTrackingOptions = function() {
  return /** @type {GeolocationPositionOptions|undefined} */ (
      this.get(ol.GeolocationProperty.TRACKING_OPTIONS));
};
 
 
/**
 * Set the projection to use for transforming the coordinates.
 * @param {ol.proj.Projection} projection The projection the position is
 *     reported in.
 * @observable
 * @api
 */
ol.Geolocation.prototype.setProjection = function(projection) {
  this.set(ol.GeolocationProperty.PROJECTION, projection);
};
 
 
/**
 * Enable or disable tracking.
 * @param {boolean} tracking Enable tracking.
 * @observable
 * @api
 */
ol.Geolocation.prototype.setTracking = function(tracking) {
  this.set(ol.GeolocationProperty.TRACKING, tracking);
};
 
 
/**
 * Set the tracking options.
 * @see http://www.w3.org/TR/geolocation-API/#position-options
 * @param {GeolocationPositionOptions} options PositionOptions as defined by the
 *     [HTML5 Geolocation spec
 *     ](http://www.w3.org/TR/geolocation-API/#position_options_interface).
 * @observable
 * @api
 */
ol.Geolocation.prototype.setTrackingOptions = function(options) {
  this.set(ol.GeolocationProperty.TRACKING_OPTIONS, options);
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/geolocationproperty.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/geolocationproperty.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 202                                      
goog.provide('ol.GeolocationProperty');
 
 
/**
 * @enum {string}
 */
ol.GeolocationProperty = {
  ACCURACY: 'accuracy',
  ACCURACY_GEOMETRY: 'accuracyGeometry',
  ALTITUDE: 'altitude',
  ALTITUDE_ACCURACY: 'altitudeAccuracy',
  HEADING: 'heading',
  POSITION: 'position',
  PROJECTION: 'projection',
  SPEED: 'speed',
  TRACKING: 'tracking',
  TRACKING_OPTIONS: 'trackingOptions'
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/graticule.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/graticule.js

Statements: 0.54% (1 / 185)      Branches: 0% (0 / 44)      Functions: 0% (0 / 13)      Lines: 0.54% (1 / 185)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 5042                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              
goog.provide('ol.Graticule');
 
goog.require('ol.extent');
goog.require('ol.geom.GeometryLayout');
goog.require('ol.geom.LineString');
goog.require('ol.geom.flat.geodesic');
goog.require('ol.math');
goog.require('ol.proj');
goog.require('ol.render.EventType');
goog.require('ol.style.Stroke');
 
 
/**
 * Render a grid for a coordinate system on a map.
 * @constructor
 * @param {olx.GraticuleOptions=} opt_options Options.
 * @api
 */
ol.Graticule = function(opt_options) {
  var options = opt_options || {};
 
 /**
  * @type {ol.Map}
  * @private
  */
  this.map_ = null;
 
 /**
  * @type {ol.proj.Projection}
  * @private
  */
  this.projection_ = null;
 
 /**
  * @type {number}
  * @private
  */
  this.maxLat_ = Infinity;
 
 /**
  * @type {number}
  * @private
  */
  this.maxLon_ = Infinity;
 
 /**
  * @type {number}
  * @private
  */
  this.minLat_ = -Infinity;
 
 /**
  * @type {number}
  * @private
  */
  this.minLon_ = -Infinity;
 
 /**
  * @type {number}
  * @private
  */
  this.maxLatP_ = Infinity;
 
 /**
  * @type {number}
  * @private
  */
  this.maxLonP_ = Infinity;
 
 /**
  * @type {number}
  * @private
  */
  this.minLatP_ = -Infinity;
 
 /**
  * @type {number}
  * @private
  */
  this.minLonP_ = -Infinity;
 
 /**
  * @type {number}
  * @private
  */
  this.targetSize_ = options.targetSize !== undefined ?
     options.targetSize : 100;
 
 /**
  * @type {number}
  * @private
  */
  this.maxLines_ = options.maxLines !== undefined ? options.maxLines : 100;
 
 /**
  * @type {Array.<ol.geom.LineString>}
  * @private
  */
  this.meridians_ = [];
 
 /**
  * @type {Array.<ol.geom.LineString>}
  * @private
  */
  this.parallels_ = [];
 
 /**
  * @type {ol.style.Stroke}
  * @private
  */
  this.strokeStyle_ = options.strokeStyle !== undefined ?
     options.strokeStyle : ol.Graticule.DEFAULT_STROKE_STYLE_;
 
 /**
  * @type {ol.TransformFunction|undefined}
  * @private
  */
  this.fromLonLatTransform_ = undefined;
 
 /**
  * @type {ol.TransformFunction|undefined}
  * @private
  */
  this.toLonLatTransform_ = undefined;
 
 /**
  * @type {ol.Coordinate}
  * @private
  */
  this.projectionCenterLonLat_ = null;
 
  this.setMap(options.map !== undefined ? options.map : null);
};
 
 
/**
 * @type {ol.style.Stroke}
 * @private
 * @const
 */
ol.Graticule.DEFAULT_STROKE_STYLE_ = new ol.style.Stroke({
  color: 'rgba(0,0,0,0.2)'
});
 
 
/**
 * TODO can be configurable
 * @type {Array.<number>}
 * @private
 */
ol.Graticule.intervals_ = [90, 45, 30, 20, 10, 5, 2, 1, 0.5, 0.2, 0.1, 0.05,
  0.01, 0.005, 0.002, 0.001];
 
 
/**
 * @param {number} lon Longitude.
 * @param {number} minLat Minimal latitude.
 * @param {number} maxLat Maximal latitude.
 * @param {number} squaredTolerance Squared tolerance.
 * @param {ol.Extent} extent Extent.
 * @param {number} index Index.
 * @return {number} Index.
 * @private
 */
ol.Graticule.prototype.addMeridian_ = function(lon, minLat, maxLat, squaredTolerance, extent, index) {
  var lineString = this.getMeridian_(lon, minLat, maxLat,
      squaredTolerance, index);
  if (ol.extent.intersects(lineString.getExtent(), extent)) {
    this.meridians_[index++] = lineString;
  }
  return index;
};
 
 
/**
 * @param {number} lat Latitude.
 * @param {number} minLon Minimal longitude.
 * @param {number} maxLon Maximal longitude.
 * @param {number} squaredTolerance Squared tolerance.
 * @param {ol.Extent} extent Extent.
 * @param {number} index Index.
 * @return {number} Index.
 * @private
 */
ol.Graticule.prototype.addParallel_ = function(lat, minLon, maxLon, squaredTolerance, extent, index) {
  var lineString = this.getParallel_(lat, minLon, maxLon, squaredTolerance,
      index);
  if (ol.extent.intersects(lineString.getExtent(), extent)) {
    this.parallels_[index++] = lineString;
  }
  return index;
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @param {ol.Coordinate} center Center.
 * @param {number} resolution Resolution.
 * @param {number} squaredTolerance Squared tolerance.
 * @private
 */
ol.Graticule.prototype.createGraticule_ = function(extent, center, resolution, squaredTolerance) {
 
  var interval = this.getInterval_(resolution);
  if (interval == -1) {
    this.meridians_.length = this.parallels_.length = 0;
    return;
  }
 
  var centerLonLat = this.toLonLatTransform_(center);
  var centerLon = centerLonLat[0];
  var centerLat = centerLonLat[1];
  var maxLines = this.maxLines_;
  var cnt, idx, lat, lon;
 
  var validExtent = [
    Math.max(extent[0], this.minLonP_),
    Math.max(extent[1], this.minLatP_),
    Math.min(extent[2], this.maxLonP_),
    Math.min(extent[3], this.maxLatP_)
  ];
 
  validExtent = ol.proj.transformExtent(validExtent, this.projection_,
      'EPSG:4326');
  var maxLat = validExtent[3];
  var maxLon = validExtent[2];
  var minLat = validExtent[1];
  var minLon = validExtent[0];
 
  // Create meridians
 
  centerLon = Math.floor(centerLon / interval) * interval;
  lon = ol.math.clamp(centerLon, this.minLon_, this.maxLon_);
 
  idx = this.addMeridian_(lon, minLat, maxLat, squaredTolerance, extent, 0);
 
  cnt = 0;
  while (lon != this.minLon_ && cnt++ < maxLines) {
    lon = Math.max(lon - interval, this.minLon_);
    idx = this.addMeridian_(lon, minLat, maxLat, squaredTolerance, extent, idx);
  }
 
  lon = ol.math.clamp(centerLon, this.minLon_, this.maxLon_);
 
  cnt = 0;
  while (lon != this.maxLon_ && cnt++ < maxLines) {
    lon = Math.min(lon + interval, this.maxLon_);
    idx = this.addMeridian_(lon, minLat, maxLat, squaredTolerance, extent, idx);
  }
 
  this.meridians_.length = idx;
 
  // Create parallels
 
  centerLat = Math.floor(centerLat / interval) * interval;
  lat = ol.math.clamp(centerLat, this.minLat_, this.maxLat_);
 
  idx = this.addParallel_(lat, minLon, maxLon, squaredTolerance, extent, 0);
 
  cnt = 0;
  while (lat != this.minLat_ && cnt++ < maxLines) {
    lat = Math.max(lat - interval, this.minLat_);
    idx = this.addParallel_(lat, minLon, maxLon, squaredTolerance, extent, idx);
  }
 
  lat = ol.math.clamp(centerLat, this.minLat_, this.maxLat_);
 
  cnt = 0;
  while (lat != this.maxLat_ && cnt++ < maxLines) {
    lat = Math.min(lat + interval, this.maxLat_);
    idx = this.addParallel_(lat, minLon, maxLon, squaredTolerance, extent, idx);
  }
 
  this.parallels_.length = idx;
 
};
 
 
/**
 * @param {number} resolution Resolution.
 * @return {number} The interval in degrees.
 * @private
 */
ol.Graticule.prototype.getInterval_ = function(resolution) {
  var centerLon = this.projectionCenterLonLat_[0];
  var centerLat = this.projectionCenterLonLat_[1];
  var interval = -1;
  var i, ii, delta, dist;
  var target = Math.pow(this.targetSize_ * resolution, 2);
  /** @type {Array.<number>} **/
  var p1 = [];
  /** @type {Array.<number>} **/
  var p2 = [];
  for (i = 0, ii = ol.Graticule.intervals_.length; i < ii; ++i) {
    delta = ol.Graticule.intervals_[i] / 2;
    p1[0] = centerLon - delta;
    p1[1] = centerLat - delta;
    p2[0] = centerLon + delta;
    p2[1] = centerLat + delta;
    this.fromLonLatTransform_(p1, p1);
    this.fromLonLatTransform_(p2, p2);
    dist = Math.pow(p2[0] - p1[0], 2) + Math.pow(p2[1] - p1[1], 2);
    if (dist <= target) {
      break;
    }
    interval = ol.Graticule.intervals_[i];
  }
  return interval;
};
 
 
/**
 * Get the map associated with this graticule.
 * @return {ol.Map} The map.
 * @api
 */
ol.Graticule.prototype.getMap = function() {
  return this.map_;
};
 
 
/**
 * @param {number} lon Longitude.
 * @param {number} minLat Minimal latitude.
 * @param {number} maxLat Maximal latitude.
 * @param {number} squaredTolerance Squared tolerance.
 * @return {ol.geom.LineString} The meridian line string.
 * @param {number} index Index.
 * @private
 */
ol.Graticule.prototype.getMeridian_ = function(lon, minLat, maxLat,
                                               squaredTolerance, index) {
  var flatCoordinates = ol.geom.flat.geodesic.meridian(lon,
     minLat, maxLat, this.projection_, squaredTolerance);
  var lineString = this.meridians_[index] !== undefined ?
     this.meridians_[index] : new ol.geom.LineString(null);
  lineString.setFlatCoordinates(ol.geom.GeometryLayout.XY, flatCoordinates);
  return lineString;
};
 
 
/**
 * Get the list of meridians.  Meridians are lines of equal longitude.
 * @return {Array.<ol.geom.LineString>} The meridians.
 * @api
 */
ol.Graticule.prototype.getMeridians = function() {
  return this.meridians_;
};
 
 
/**
 * @param {number} lat Latitude.
 * @param {number} minLon Minimal longitude.
 * @param {number} maxLon Maximal longitude.
 * @param {number} squaredTolerance Squared tolerance.
 * @return {ol.geom.LineString} The parallel line string.
 * @param {number} index Index.
 * @private
 */
ol.Graticule.prototype.getParallel_ = function(lat, minLon, maxLon,
                                               squaredTolerance, index) {
  var flatCoordinates = ol.geom.flat.geodesic.parallel(lat,
     this.minLon_, this.maxLon_, this.projection_, squaredTolerance);
  var lineString = this.parallels_[index] !== undefined ?
     this.parallels_[index] : new ol.geom.LineString(null);
  lineString.setFlatCoordinates(ol.geom.GeometryLayout.XY, flatCoordinates);
  return lineString;
};
 
 
/**
 * Get the list of parallels.  Pallels are lines of equal latitude.
 * @return {Array.<ol.geom.LineString>} The parallels.
 * @api
 */
ol.Graticule.prototype.getParallels = function() {
  return this.parallels_;
};
 
 
/**
 * @param {ol.render.Event} e Event.
 * @private
 */
ol.Graticule.prototype.handlePostCompose_ = function(e) {
  var vectorContext = e.vectorContext;
  var frameState = e.frameState;
  var extent = frameState.extent;
  var viewState = frameState.viewState;
  var center = viewState.center;
  var projection = viewState.projection;
  var resolution = viewState.resolution;
  var pixelRatio = frameState.pixelRatio;
  var squaredTolerance =
      resolution * resolution / (4 * pixelRatio * pixelRatio);
 
  var updateProjectionInfo = !this.projection_ ||
      !ol.proj.equivalent(this.projection_, projection);
 
  if (updateProjectionInfo) {
    this.updateProjectionInfo_(projection);
  }
 
  //Fix the extent if wrapped.
  //(note: this is the same extent as vectorContext.extent_)
  var offsetX = 0;
  if (projection.canWrapX()) {
    var projectionExtent = projection.getExtent();
    var worldWidth = ol.extent.getWidth(projectionExtent);
    var x = frameState.focus[0];
    if (x < projectionExtent[0] || x > projectionExtent[2]) {
      var worldsAway = Math.ceil((projectionExtent[0] - x) / worldWidth);
      offsetX = worldWidth * worldsAway;
      extent = [
        extent[0] + offsetX, extent[1],
        extent[2] + offsetX, extent[3]
      ];
    }
  }
 
  this.createGraticule_(extent, center, resolution, squaredTolerance);
 
  // Draw the lines
  vectorContext.setFillStrokeStyle(null, this.strokeStyle_);
  var i, l, line;
  for (i = 0, l = this.meridians_.length; i < l; ++i) {
    line = this.meridians_[i];
    vectorContext.drawLineString(line, null);
  }
  for (i = 0, l = this.parallels_.length; i < l; ++i) {
    line = this.parallels_[i];
    vectorContext.drawLineString(line, null);
  }
};
 
 
/**
 * @param {ol.proj.Projection} projection Projection.
 * @private
 */
ol.Graticule.prototype.updateProjectionInfo_ = function(projection) {
  var epsg4326Projection = ol.proj.get('EPSG:4326');
 
  var extent = projection.getExtent();
  var worldExtent = projection.getWorldExtent();
  var worldExtentP = ol.proj.transformExtent(worldExtent,
     epsg4326Projection, projection);
 
  var maxLat = worldExtent[3];
  var maxLon = worldExtent[2];
  var minLat = worldExtent[1];
  var minLon = worldExtent[0];
 
  var maxLatP = worldExtentP[3];
  var maxLonP = worldExtentP[2];
  var minLatP = worldExtentP[1];
  var minLonP = worldExtentP[0];
 
  this.maxLat_ = maxLat;
  this.maxLon_ = maxLon;
  this.minLat_ = minLat;
  this.minLon_ = minLon;
 
  this.maxLatP_ = maxLatP;
  this.maxLonP_ = maxLonP;
  this.minLatP_ = minLatP;
  this.minLonP_ = minLonP;
 
 
  this.fromLonLatTransform_ = ol.proj.getTransform(
     epsg4326Projection, projection);
 
  this.toLonLatTransform_ = ol.proj.getTransform(
     projection, epsg4326Projection);
 
  this.projectionCenterLonLat_ = this.toLonLatTransform_(
     ol.extent.getCenter(extent));
 
  this.projection_ = projection;
};
 
 
/**
 * Set the map for this graticule.  The graticule will be rendered on the
 * provided map.
 * @param {ol.Map} map Map.
 * @api
 */
ol.Graticule.prototype.setMap = function(map) {
  if (this.map_) {
    this.map_.un(ol.render.EventType.POSTCOMPOSE,
        this.handlePostCompose_, this);
    this.map_.render();
  }
  if (map) {
    map.on(ol.render.EventType.POSTCOMPOSE,
        this.handlePostCompose_, this);
    map.render();
  }
  this.map_ = map;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/has.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/has.js

Statements: 2.33% (1 / 43)      Branches: 0% (0 / 24)      Functions: 0% (0 / 2)      Lines: 2.33% (1 / 43)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 1642                                                                                                                                                                                                                                                                                                                                      
goog.provide('ol.has');
 
goog.require('ol');
goog.require('ol.webgl');
 
var ua = typeof navigator !== 'undefined' ?
    navigator.userAgent.toLowerCase() : '';
 
/**
 * User agent string says we are dealing with Firefox as browser.
 * @type {boolean}
 */
ol.has.FIREFOX = ua.indexOf('firefox') !== -1;
 
/**
 * User agent string says we are dealing with Safari as browser.
 * @type {boolean}
 */
ol.has.SAFARI = ua.indexOf('safari') !== -1 && ua.indexOf('chrom') == -1;
 
/**
 * User agent string says we are dealing with a WebKit engine.
 * @type {boolean}
 */
ol.has.WEBKIT = ua.indexOf('webkit') !== -1 && ua.indexOf('edge') == -1;
 
/**
 * User agent string says we are dealing with a Mac as platform.
 * @type {boolean}
 */
ol.has.MAC = ua.indexOf('macintosh') !== -1;
 
 
/**
 * The ratio between physical pixels and device-independent pixels
 * (dips) on the device (`window.devicePixelRatio`).
 * @const
 * @type {number}
 * @api
 */
ol.has.DEVICE_PIXEL_RATIO = window.devicePixelRatio || 1;
 
 
/**
 * True if the browser's Canvas implementation implements {get,set}LineDash.
 * @type {boolean}
 */
ol.has.CANVAS_LINE_DASH = false;
 
 
/**
 * True if both the library and browser support Canvas.  Always `false`
 * if `ol.ENABLE_CANVAS` is set to `false` at compile time.
 * @const
 * @type {boolean}
 * @api
 */
ol.has.CANVAS = ol.ENABLE_CANVAS && (
    /**
     * @return {boolean} Canvas supported.
     */
    function() {
      if (!('HTMLCanvasElement' in window)) {
        return false;
      }
      try {
        var context = document.createElement('CANVAS').getContext('2d');
        if (!context) {
          return false;
        } else {
          if (context.setLineDash !== undefined) {
            ol.has.CANVAS_LINE_DASH = true;
          }
          return true;
        }
      } catch (e) {
        return false;
      }
    })();
 
 
/**
 * Indicates if DeviceOrientation is supported in the user's browser.
 * @const
 * @type {boolean}
 * @api
 */
ol.has.DEVICE_ORIENTATION = 'DeviceOrientationEvent' in window;
 
 
/**
 * Is HTML5 geolocation supported in the current browser?
 * @const
 * @type {boolean}
 * @api
 */
ol.has.GEOLOCATION = 'geolocation' in navigator;
 
 
/**
 * True if browser supports touch events.
 * @const
 * @type {boolean}
 * @api
 */
ol.has.TOUCH = ol.ASSUME_TOUCH || 'ontouchstart' in window;
 
 
/**
 * True if browser supports pointer events.
 * @const
 * @type {boolean}
 */
ol.has.POINTER = 'PointerEvent' in window;
 
 
/**
 * True if browser supports ms pointer events (IE 10).
 * @const
 * @type {boolean}
 */
ol.has.MSPOINTER = !!(navigator.msPointerEnabled);
 
 
/**
 * True if both OpenLayers and browser support WebGL.  Always `false`
 * if `ol.ENABLE_WEBGL` is set to `false` at compile time.
 * @const
 * @type {boolean}
 * @api
 */
ol.has.WEBGL;
 
 
(function() {
  if (ol.ENABLE_WEBGL) {
    var hasWebGL = false;
    var textureSize;
    var /** @type {Array.<string>} */ extensions = [];
 
    if ('WebGLRenderingContext' in window) {
      try {
        var canvas = /** @type {HTMLCanvasElement} */
            (document.createElement('CANVAS'));
        var gl = ol.webgl.getContext(canvas, {
          failIfMajorPerformanceCaveat: true
        });
        if (gl) {
          hasWebGL = true;
          textureSize = /** @type {number} */
              (gl.getParameter(gl.MAX_TEXTURE_SIZE));
          extensions = gl.getSupportedExtensions();
        }
      } catch (e) {
        // pass
      }
    }
    ol.has.WEBGL = hasWebGL;
    ol.WEBGL_EXTENSIONS = extensions;
    ol.WEBGL_MAX_TEXTURE_SIZE = textureSize;
  }
})();
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/image.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/image.js

Statements: 1.92% (1 / 52)      Branches: 0% (0 / 14)      Functions: 0% (0 / 7)      Lines: 1.92% (1 / 52)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 1622                                                                                                                                                                                                                                                                                                                                  
goog.provide('ol.Image');
 
goog.require('ol');
goog.require('ol.ImageBase');
goog.require('ol.ImageState');
goog.require('ol.events');
goog.require('ol.events.EventType');
goog.require('ol.extent');
goog.require('ol.obj');
 
 
/**
 * @constructor
 * @extends {ol.ImageBase}
 * @param {ol.Extent} extent Extent.
 * @param {number|undefined} resolution Resolution.
 * @param {number} pixelRatio Pixel ratio.
 * @param {Array.<ol.Attribution>} attributions Attributions.
 * @param {string} src Image source URI.
 * @param {?string} crossOrigin Cross origin.
 * @param {ol.ImageLoadFunctionType} imageLoadFunction Image load function.
 */
ol.Image = function(extent, resolution, pixelRatio, attributions, src,
    crossOrigin, imageLoadFunction) {
 
  ol.ImageBase.call(this, extent, resolution, pixelRatio, ol.ImageState.IDLE,
      attributions);
 
  /**
   * @private
   * @type {string}
   */
  this.src_ = src;
 
  /**
   * @private
   * @type {HTMLCanvasElement|Image|HTMLVideoElement}
   */
  this.image_ = new Image();
  if (crossOrigin !== null) {
    this.image_.crossOrigin = crossOrigin;
  }
 
  /**
   * @private
   * @type {Object.<number, (HTMLCanvasElement|Image|HTMLVideoElement)>}
   */
  this.imageByContext_ = {};
 
  /**
   * @private
   * @type {Array.<ol.EventsKey>}
   */
  this.imageListenerKeys_ = null;
 
  /**
   * @protected
   * @type {ol.ImageState}
   */
  this.state = ol.ImageState.IDLE;
 
  /**
   * @private
   * @type {ol.ImageLoadFunctionType}
   */
  this.imageLoadFunction_ = imageLoadFunction;
 
};
ol.inherits(ol.Image, ol.ImageBase);
 
 
/**
 * @inheritDoc
 * @api
 */
ol.Image.prototype.getImage = function(opt_context) {
  if (opt_context !== undefined) {
    var image;
    var key = ol.getUid(opt_context);
    if (key in this.imageByContext_) {
      return this.imageByContext_[key];
    } else if (ol.obj.isEmpty(this.imageByContext_)) {
      image = this.image_;
    } else {
      image = /** @type {Image} */ (this.image_.cloneNode(false));
    }
    this.imageByContext_[key] = image;
    return image;
  } else {
    return this.image_;
  }
};
 
 
/**
 * Tracks loading or read errors.
 *
 * @private
 */
ol.Image.prototype.handleImageError_ = function() {
  this.state = ol.ImageState.ERROR;
  this.unlistenImage_();
  this.changed();
};
 
 
/**
 * Tracks successful image load.
 *
 * @private
 */
ol.Image.prototype.handleImageLoad_ = function() {
  if (this.resolution === undefined) {
    this.resolution = ol.extent.getHeight(this.extent) / this.image_.height;
  }
  this.state = ol.ImageState.LOADED;
  this.unlistenImage_();
  this.changed();
};
 
 
/**
 * Load the image or retry if loading previously failed.
 * Loading is taken care of by the tile queue, and calling this method is
 * only needed for preloading or for reloading in case of an error.
 * @override
 * @api
 */
ol.Image.prototype.load = function() {
  if (this.state == ol.ImageState.IDLE || this.state == ol.ImageState.ERROR) {
    this.state = ol.ImageState.LOADING;
    this.changed();
    this.imageListenerKeys_ = [
      ol.events.listenOnce(this.image_, ol.events.EventType.ERROR,
          this.handleImageError_, this),
      ol.events.listenOnce(this.image_, ol.events.EventType.LOAD,
          this.handleImageLoad_, this)
    ];
    this.imageLoadFunction_(this, this.src_);
  }
};
 
 
/**
 * @param {HTMLCanvasElement|Image|HTMLVideoElement} image Image.
 */
ol.Image.prototype.setImage = function(image) {
  this.image_ = image;
};
 
 
/**
 * Discards event handlers which listen for load completion or errors.
 *
 * @private
 */
ol.Image.prototype.unlistenImage_ = function() {
  this.imageListenerKeys_.forEach(ol.events.unlistenByKey);
  this.imageListenerKeys_ = null;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/imagebase.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/imagebase.js

Statements: 3.85% (1 / 26)      Branches: 100% (0 / 0)      Functions: 0% (0 / 9)      Lines: 3.85% (1 / 26)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 1182                                                                                                                                                                                                                                          
goog.provide('ol.ImageBase');
 
goog.require('ol');
goog.require('ol.events.EventTarget');
goog.require('ol.events.EventType');
 
 
/**
 * @constructor
 * @abstract
 * @extends {ol.events.EventTarget}
 * @param {ol.Extent} extent Extent.
 * @param {number|undefined} resolution Resolution.
 * @param {number} pixelRatio Pixel ratio.
 * @param {ol.ImageState} state State.
 * @param {Array.<ol.Attribution>} attributions Attributions.
 */
ol.ImageBase = function(extent, resolution, pixelRatio, state, attributions) {
 
  ol.events.EventTarget.call(this);
 
  /**
   * @private
   * @type {Array.<ol.Attribution>}
   */
  this.attributions_ = attributions;
 
  /**
   * @protected
   * @type {ol.Extent}
   */
  this.extent = extent;
 
  /**
   * @private
   * @type {number}
   */
  this.pixelRatio_ = pixelRatio;
 
  /**
   * @protected
   * @type {number|undefined}
   */
  this.resolution = resolution;
 
  /**
   * @protected
   * @type {ol.ImageState}
   */
  this.state = state;
 
};
ol.inherits(ol.ImageBase, ol.events.EventTarget);
 
 
/**
 * @protected
 */
ol.ImageBase.prototype.changed = function() {
  this.dispatchEvent(ol.events.EventType.CHANGE);
};
 
 
/**
 * @return {Array.<ol.Attribution>} Attributions.
 */
ol.ImageBase.prototype.getAttributions = function() {
  return this.attributions_;
};
 
 
/**
 * @return {ol.Extent} Extent.
 */
ol.ImageBase.prototype.getExtent = function() {
  return this.extent;
};
 
 
/**
 * @abstract
 * @param {Object=} opt_context Object.
 * @return {HTMLCanvasElement|Image|HTMLVideoElement} Image.
 */
ol.ImageBase.prototype.getImage = function(opt_context) {};
 
 
/**
 * @return {number} PixelRatio.
 */
ol.ImageBase.prototype.getPixelRatio = function() {
  return this.pixelRatio_;
};
 
 
/**
 * @return {number} Resolution.
 */
ol.ImageBase.prototype.getResolution = function() {
  return /** @type {number} */ (this.resolution);
};
 
 
/**
 * @return {ol.ImageState} State.
 */
ol.ImageBase.prototype.getState = function() {
  return this.state;
};
 
 
/**
 * Load not yet loaded URI.
 * @abstract
 */
ol.ImageBase.prototype.load = function() {};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/imagecanvas.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/imagecanvas.js

Statements: 3.85% (1 / 26)      Branches: 0% (0 / 8)      Functions: 0% (0 / 5)      Lines: 3.85% (1 / 26)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 942                                                                                                                                                                                          
goog.provide('ol.ImageCanvas');
 
goog.require('ol');
goog.require('ol.ImageBase');
goog.require('ol.ImageState');
 
 
/**
 * @constructor
 * @extends {ol.ImageBase}
 * @param {ol.Extent} extent Extent.
 * @param {number} resolution Resolution.
 * @param {number} pixelRatio Pixel ratio.
 * @param {Array.<ol.Attribution>} attributions Attributions.
 * @param {HTMLCanvasElement} canvas Canvas.
 * @param {ol.ImageCanvasLoader=} opt_loader Optional loader function to
 *     support asynchronous canvas drawing.
 */
ol.ImageCanvas = function(extent, resolution, pixelRatio, attributions,
    canvas, opt_loader) {
 
  /**
   * Optional canvas loader function.
   * @type {?ol.ImageCanvasLoader}
   * @private
   */
  this.loader_ = opt_loader !== undefined ? opt_loader : null;
 
  var state = opt_loader !== undefined ?
      ol.ImageState.IDLE : ol.ImageState.LOADED;
 
  ol.ImageBase.call(this, extent, resolution, pixelRatio, state, attributions);
 
  /**
   * @private
   * @type {HTMLCanvasElement}
   */
  this.canvas_ = canvas;
 
  /**
   * @private
   * @type {Error}
   */
  this.error_ = null;
 
};
ol.inherits(ol.ImageCanvas, ol.ImageBase);
 
 
/**
 * Get any error associated with asynchronous rendering.
 * @return {Error} Any error that occurred during rendering.
 */
ol.ImageCanvas.prototype.getError = function() {
  return this.error_;
};
 
 
/**
 * Handle async drawing complete.
 * @param {Error} err Any error during drawing.
 * @private
 */
ol.ImageCanvas.prototype.handleLoad_ = function(err) {
  if (err) {
    this.error_ = err;
    this.state = ol.ImageState.ERROR;
  } else {
    this.state = ol.ImageState.LOADED;
  }
  this.changed();
};
 
 
/**
 * @inheritDoc
 */
ol.ImageCanvas.prototype.load = function() {
  if (this.state == ol.ImageState.IDLE) {
    this.state = ol.ImageState.LOADING;
    this.changed();
    this.loader_(this.handleLoad_.bind(this));
  }
};
 
 
/**
 * @inheritDoc
 */
ol.ImageCanvas.prototype.getImage = function(opt_context) {
  return this.canvas_;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/imagestate.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/imagestate.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 132                        
goog.provide('ol.ImageState');
 
/**
 * @enum {number}
 */
ol.ImageState = {
  IDLE: 0,
  LOADING: 1,
  LOADED: 2,
  ERROR: 3
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/imagetile.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/imagetile.js

Statements: 2.17% (1 / 46)      Branches: 0% (0 / 14)      Functions: 0% (0 / 8)      Lines: 2.17% (1 / 46)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 1472                                                                                                                                                                                                                                                                                                    
goog.provide('ol.ImageTile');
 
goog.require('ol');
goog.require('ol.Tile');
goog.require('ol.TileState');
goog.require('ol.events');
goog.require('ol.events.EventType');
 
 
/**
 * @constructor
 * @extends {ol.Tile}
 * @param {ol.TileCoord} tileCoord Tile coordinate.
 * @param {ol.TileState} state State.
 * @param {string} src Image source URI.
 * @param {?string} crossOrigin Cross origin.
 * @param {ol.TileLoadFunctionType} tileLoadFunction Tile load function.
 */
ol.ImageTile = function(tileCoord, state, src, crossOrigin, tileLoadFunction) {
 
  ol.Tile.call(this, tileCoord, state);
 
  /**
   * Image URI
   *
   * @private
   * @type {string}
   */
  this.src_ = src;
 
  /**
   * @private
   * @type {Image}
   */
  this.image_ = new Image();
  if (crossOrigin !== null) {
    this.image_.crossOrigin = crossOrigin;
  }
 
  /**
   * @private
   * @type {Array.<ol.EventsKey>}
   */
  this.imageListenerKeys_ = null;
 
  /**
   * @private
   * @type {ol.TileLoadFunctionType}
   */
  this.tileLoadFunction_ = tileLoadFunction;
 
};
ol.inherits(ol.ImageTile, ol.Tile);
 
 
/**
 * @inheritDoc
 */
ol.ImageTile.prototype.disposeInternal = function() {
  if (this.state == ol.TileState.LOADING) {
    this.unlistenImage_();
  }
  if (this.interimTile) {
    this.interimTile.dispose();
  }
  this.state = ol.TileState.ABORT;
  this.changed();
  ol.Tile.prototype.disposeInternal.call(this);
};
 
 
/**
 * Get the image element for this tile.
 * @inheritDoc
 * @api
 */
ol.ImageTile.prototype.getImage = function() {
  return this.image_;
};
 
 
/**
 * @inheritDoc
 */
ol.ImageTile.prototype.getKey = function() {
  return this.src_;
};
 
 
/**
 * Tracks loading or read errors.
 *
 * @private
 */
ol.ImageTile.prototype.handleImageError_ = function() {
  this.state = ol.TileState.ERROR;
  this.unlistenImage_();
  this.changed();
};
 
 
/**
 * Tracks successful image load.
 *
 * @private
 */
ol.ImageTile.prototype.handleImageLoad_ = function() {
  if (this.image_.naturalWidth && this.image_.naturalHeight) {
    this.state = ol.TileState.LOADED;
  } else {
    this.state = ol.TileState.EMPTY;
  }
  this.unlistenImage_();
  this.changed();
};
 
 
/**
 * @inheritDoc
 * @api
 */
ol.ImageTile.prototype.load = function() {
  if (this.state == ol.TileState.IDLE || this.state == ol.TileState.ERROR) {
    this.state = ol.TileState.LOADING;
    this.changed();
    this.imageListenerKeys_ = [
      ol.events.listenOnce(this.image_, ol.events.EventType.ERROR,
          this.handleImageError_, this),
      ol.events.listenOnce(this.image_, ol.events.EventType.LOAD,
          this.handleImageLoad_, this)
    ];
    this.tileLoadFunction_(this, this.src_);
  }
};
 
 
/**
 * Discards event handlers which listen for load completion or errors.
 *
 * @private
 */
ol.ImageTile.prototype.unlistenImage_ = function() {
  this.imageListenerKeys_.forEach(ol.events.unlistenByKey);
  this.imageListenerKeys_ = null;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/interaction.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/interaction.js

Statements: 2.38% (1 / 42)      Branches: 0% (0 / 34)      Functions: 0% (0 / 1)      Lines: 2.38% (1 / 42)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 1132                                                                                                                                                                                                                                
goog.provide('ol.interaction');
 
goog.require('ol.Collection');
goog.require('ol.Kinetic');
goog.require('ol.interaction.DoubleClickZoom');
goog.require('ol.interaction.DragPan');
goog.require('ol.interaction.DragRotate');
goog.require('ol.interaction.DragZoom');
goog.require('ol.interaction.KeyboardPan');
goog.require('ol.interaction.KeyboardZoom');
goog.require('ol.interaction.MouseWheelZoom');
goog.require('ol.interaction.PinchRotate');
goog.require('ol.interaction.PinchZoom');
 
 
/**
 * Set of interactions included in maps by default. Specific interactions can be
 * excluded by setting the appropriate option to false in the constructor
 * options, but the order of the interactions is fixed.  If you want to specify
 * a different order for interactions, you will need to create your own
 * {@link ol.interaction.Interaction} instances and insert them into a
 * {@link ol.Collection} in the order you want before creating your
 * {@link ol.Map} instance. The default set of interactions, in sequence, is:
 * * {@link ol.interaction.DragRotate}
 * * {@link ol.interaction.DoubleClickZoom}
 * * {@link ol.interaction.DragPan}
 * * {@link ol.interaction.PinchRotate}
 * * {@link ol.interaction.PinchZoom}
 * * {@link ol.interaction.KeyboardPan}
 * * {@link ol.interaction.KeyboardZoom}
 * * {@link ol.interaction.MouseWheelZoom}
 * * {@link ol.interaction.DragZoom}
 *
 * @param {olx.interaction.DefaultsOptions=} opt_options Defaults options.
 * @return {ol.Collection.<ol.interaction.Interaction>} A collection of
 * interactions to be used with the ol.Map constructor's interactions option.
 * @api
 */
ol.interaction.defaults = function(opt_options) {
 
  var options = opt_options ? opt_options : {};
 
  var interactions = new ol.Collection();
 
  var kinetic = new ol.Kinetic(-0.005, 0.05, 100);
 
  var altShiftDragRotate = options.altShiftDragRotate !== undefined ?
      options.altShiftDragRotate : true;
  if (altShiftDragRotate) {
    interactions.push(new ol.interaction.DragRotate());
  }
 
  var doubleClickZoom = options.doubleClickZoom !== undefined ?
      options.doubleClickZoom : true;
  if (doubleClickZoom) {
    interactions.push(new ol.interaction.DoubleClickZoom({
      delta: options.zoomDelta,
      duration: options.zoomDuration
    }));
  }
 
  var dragPan = options.dragPan !== undefined ? options.dragPan : true;
  if (dragPan) {
    interactions.push(new ol.interaction.DragPan({
      kinetic: kinetic
    }));
  }
 
  var pinchRotate = options.pinchRotate !== undefined ? options.pinchRotate :
      true;
  if (pinchRotate) {
    interactions.push(new ol.interaction.PinchRotate());
  }
 
  var pinchZoom = options.pinchZoom !== undefined ? options.pinchZoom : true;
  if (pinchZoom) {
    interactions.push(new ol.interaction.PinchZoom({
      constrainResolution: options.constrainResolution,
      duration: options.zoomDuration
    }));
  }
 
  var keyboard = options.keyboard !== undefined ? options.keyboard : true;
  if (keyboard) {
    interactions.push(new ol.interaction.KeyboardPan());
    interactions.push(new ol.interaction.KeyboardZoom({
      delta: options.zoomDelta,
      duration: options.zoomDuration
    }));
  }
 
  var mouseWheelZoom = options.mouseWheelZoom !== undefined ?
      options.mouseWheelZoom : true;
  if (mouseWheelZoom) {
    interactions.push(new ol.interaction.MouseWheelZoom({
      constrainResolution: options.constrainResolution,
      duration: options.zoomDuration
    }));
  }
 
  var shiftDragZoom = options.shiftDragZoom !== undefined ?
      options.shiftDragZoom : true;
  if (shiftDragZoom) {
    interactions.push(new ol.interaction.DragZoom({
      duration: options.zoomDuration
    }));
  }
 
  return interactions;
 
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/kinetic.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/kinetic.js

Statements: 2.94% (1 / 34)      Branches: 0% (0 / 6)      Functions: 0% (0 / 6)      Lines: 2.94% (1 / 34)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 1212                                                                                                                                                                                                                                                
goog.provide('ol.Kinetic');
 
 
/**
 * @classdesc
 * Implementation of inertial deceleration for map movement.
 *
 * @constructor
 * @param {number} decay Rate of decay (must be negative).
 * @param {number} minVelocity Minimum velocity (pixels/millisecond).
 * @param {number} delay Delay to consider to calculate the kinetic
 *     initial values (milliseconds).
 * @struct
 * @api
 */
ol.Kinetic = function(decay, minVelocity, delay) {
 
  /**
   * @private
   * @type {number}
   */
  this.decay_ = decay;
 
  /**
   * @private
   * @type {number}
   */
  this.minVelocity_ = minVelocity;
 
  /**
   * @private
   * @type {number}
   */
  this.delay_ = delay;
 
  /**
   * @private
   * @type {Array.<number>}
   */
  this.points_ = [];
 
  /**
   * @private
   * @type {number}
   */
  this.angle_ = 0;
 
  /**
   * @private
   * @type {number}
   */
  this.initialVelocity_ = 0;
};
 
 
/**
 * FIXME empty description for jsdoc
 */
ol.Kinetic.prototype.begin = function() {
  this.points_.length = 0;
  this.angle_ = 0;
  this.initialVelocity_ = 0;
};
 
 
/**
 * @param {number} x X.
 * @param {number} y Y.
 */
ol.Kinetic.prototype.update = function(x, y) {
  this.points_.push(x, y, Date.now());
};
 
 
/**
 * @return {boolean} Whether we should do kinetic animation.
 */
ol.Kinetic.prototype.end = function() {
  if (this.points_.length < 6) {
    // at least 2 points are required (i.e. there must be at least 6 elements
    // in the array)
    return false;
  }
  var delay = Date.now() - this.delay_;
  var lastIndex = this.points_.length - 3;
  if (this.points_[lastIndex + 2] < delay) {
    // the last tracked point is too old, which means that the user stopped
    // panning before releasing the map
    return false;
  }
 
  // get the first point which still falls into the delay time
  var firstIndex = lastIndex - 3;
  while (firstIndex > 0 && this.points_[firstIndex + 2] > delay) {
    firstIndex -= 3;
  }
  var duration = this.points_[lastIndex + 2] - this.points_[firstIndex + 2];
  var dx = this.points_[lastIndex] - this.points_[firstIndex];
  var dy = this.points_[lastIndex + 1] - this.points_[firstIndex + 1];
  this.angle_ = Math.atan2(dy, dx);
  this.initialVelocity_ = Math.sqrt(dx * dx + dy * dy) / duration;
  return this.initialVelocity_ > this.minVelocity_;
};
 
 
/**
 * @return {number} Total distance travelled (pixels).
 */
ol.Kinetic.prototype.getDistance = function() {
  return (this.minVelocity_ - this.initialVelocity_) / this.decay_;
};
 
 
/**
 * @return {number} Angle of the kinetic panning animation (radians).
 */
ol.Kinetic.prototype.getAngle = function() {
  return this.angle_;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/loadingstrategy.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/loadingstrategy.js

Statements: 6.67% (1 / 15)      Branches: 100% (0 / 0)      Functions: 0% (0 / 4)      Lines: 6.67% (1 / 15)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 602                                                                                                                      
goog.provide('ol.loadingstrategy');
 
 
/**
 * Strategy function for loading all features with a single request.
 * @param {ol.Extent} extent Extent.
 * @param {number} resolution Resolution.
 * @return {Array.<ol.Extent>} Extents.
 * @api
 */
ol.loadingstrategy.all = function(extent, resolution) {
  return [[-Infinity, -Infinity, Infinity, Infinity]];
};
 
 
/**
 * Strategy function for loading features based on the view's extent and
 * resolution.
 * @param {ol.Extent} extent Extent.
 * @param {number} resolution Resolution.
 * @return {Array.<ol.Extent>} Extents.
 * @api
 */
ol.loadingstrategy.bbox = function(extent, resolution) {
  return [extent];
};
 
 
/**
 * Creates a strategy function for loading features based on a tile grid.
 * @param {ol.tilegrid.TileGrid} tileGrid Tile grid.
 * @return {function(ol.Extent, number): Array.<ol.Extent>} Loading strategy.
 * @api
 */
ol.loadingstrategy.tile = function(tileGrid) {
  return (
      /**
       * @param {ol.Extent} extent Extent.
       * @param {number} resolution Resolution.
       * @return {Array.<ol.Extent>} Extents.
       */
      function(extent, resolution) {
        var z = tileGrid.getZForResolution(resolution);
        var tileRange = tileGrid.getTileRangeForExtentAndZ(extent, z);
        /** @type {Array.<ol.Extent>} */
        var extents = [];
        /** @type {ol.TileCoord} */
        var tileCoord = [z, 0, 0];
        for (tileCoord[1] = tileRange.minX; tileCoord[1] <= tileRange.maxX;
             ++tileCoord[1]) {
          for (tileCoord[2] = tileRange.minY; tileCoord[2] <= tileRange.maxY;
               ++tileCoord[2]) {
            extents.push(tileGrid.getTileCoordExtent(tileCoord));
          }
        }
        return extents;
      });
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/map.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/map.js

Statements: 0.22% (1 / 446)      Branches: 0% (0 / 182)      Functions: 0% (0 / 63)      Lines: 0.22% (1 / 446)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504        2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      
// FIXME recheck layer/map projection compatibility when projection changes
// FIXME layer renderers should skip when they can't reproject
// FIXME add tilt and height?
 
goog.provide('ol.Map');
 
goog.require('ol');
goog.require('ol.Collection');
goog.require('ol.CollectionEventType');
goog.require('ol.MapBrowserEvent');
goog.require('ol.MapBrowserEventHandler');
goog.require('ol.MapBrowserEventType');
goog.require('ol.MapEvent');
goog.require('ol.MapEventType');
goog.require('ol.MapProperty');
goog.require('ol.Object');
goog.require('ol.ObjectEventType');
goog.require('ol.TileQueue');
goog.require('ol.View');
goog.require('ol.ViewHint');
goog.require('ol.asserts');
goog.require('ol.control');
goog.require('ol.dom');
goog.require('ol.events');
goog.require('ol.events.Event');
goog.require('ol.events.EventType');
goog.require('ol.extent');
goog.require('ol.functions');
goog.require('ol.has');
goog.require('ol.interaction');
goog.require('ol.layer.Group');
goog.require('ol.obj');
goog.require('ol.renderer.Map');
goog.require('ol.renderer.Type');
goog.require('ol.renderer.canvas.Map');
goog.require('ol.renderer.webgl.Map');
goog.require('ol.size');
goog.require('ol.structs.PriorityQueue');
goog.require('ol.transform');
 
 
/**
 * @const
 * @type {string}
 */
ol.OL_URL = 'https://openlayers.org/';
 
 
/**
 * @const
 * @type {string}
 */
ol.OL_LOGO_URL = 'data:image/png;base64,' +
    'iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAAA3NCSVQICAjb4U/gAAAACXBI' +
    'WXMAAAHGAAABxgEXwfpGAAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAA' +
    'AhNQTFRF////AP//AICAgP//AFVVQECA////K1VVSbbbYL/fJ05idsTYJFtbbcjbJllmZszW' +
    'WMTOIFhoHlNiZszTa9DdUcHNHlNlV8XRIVdiasrUHlZjIVZjaMnVH1RlIFRkH1RkH1ZlasvY' +
    'asvXVsPQH1VkacnVa8vWIVZjIFRjVMPQa8rXIVVkXsXRsNveIFVkIFZlIVVj3eDeh6GmbMvX' +
    'H1ZkIFRka8rWbMvXIFVkIFVjIFVkbMvWH1VjbMvWIFVlbcvWIFVla8vVIFVkbMvWbMvVH1Vk' +
    'bMvWIFVlbcvWIFVkbcvVbMvWjNPbIFVkU8LPwMzNIFVkbczWIFVkbsvWbMvXIFVkRnB8bcvW' +
    '2+TkW8XRIFVkIlZlJVloJlpoKlxrLl9tMmJwOWd0Omh1RXF8TneCT3iDUHiDU8LPVMLPVcLP' +
    'VcPQVsPPVsPQV8PQWMTQWsTQW8TQXMXSXsXRX4SNX8bSYMfTYcfTYsfTY8jUZcfSZsnUaIqT' +
    'acrVasrVa8jTa8rWbI2VbMvWbcvWdJObdcvUdszUd8vVeJaee87Yfc3WgJyjhqGnitDYjaar' +
    'ldPZnrK2oNbborW5o9bbo9fbpLa6q9ndrL3ArtndscDDutzfu8fJwN7gwt7gxc/QyuHhy+Hi' +
    'zeHi0NfX0+Pj19zb1+Tj2uXk29/e3uLg3+Lh3+bl4uXj4ufl4+fl5Ofl5ufl5ujm5+jmySDn' +
    'BAAAAFp0Uk5TAAECAgMEBAYHCA0NDg4UGRogIiMmKSssLzU7PkJJT1JTVFliY2hrdHZ3foSF' +
    'hYeJjY2QkpugqbG1tre5w8zQ09XY3uXn6+zx8vT09vf4+Pj5+fr6/P39/f3+gz7SsAAAAVVJ' +
    'REFUOMtjYKA7EBDnwCPLrObS1BRiLoJLnte6CQy8FLHLCzs2QUG4FjZ5GbcmBDDjxJBXDWxC' +
    'Brb8aM4zbkIDzpLYnAcE9VXlJSWlZRU13koIeW57mGx5XjoMZEUqwxWYQaQbSzLSkYGfKFSe' +
    '0QMsX5WbjgY0YS4MBplemI4BdGBW+DQ11eZiymfqQuXZIjqwyadPNoSZ4L+0FVM6e+oGI6g8' +
    'a9iKNT3o8kVzNkzRg5lgl7p4wyRUL9Yt2jAxVh6mQCogae6GmflI8p0r13VFWTHBQ0rWPW7a' +
    'hgWVcPm+9cuLoyy4kCJDzCm6d8PSFoh0zvQNC5OjDJhQopPPJqph1doJBUD5tnkbZiUEqaCn' +
    'B3bTqLTFG1bPn71kw4b+GFdpLElKIzRxxgYgWNYc5SCENVHKeUaltHdXx0dZ8uBI1hJ2UUDg' +
    'q82CM2MwKeibqAvSO7MCABq0wXEPiqWEAAAAAElFTkSuQmCC';
 
 
/**
 * @type {Array.<ol.renderer.Type>}
 * @const
 */
ol.DEFAULT_RENDERER_TYPES = [
  ol.renderer.Type.CANVAS,
  ol.renderer.Type.WEBGL
];
 
 
/**
 * @classdesc
 * The map is the core component of OpenLayers. For a map to render, a view,
 * one or more layers, and a target container are needed:
 *
 *     var map = new ol.Map({
 *       view: new ol.View({
 *         center: [0, 0],
 *         zoom: 1
 *       }),
 *       layers: [
 *         new ol.layer.Tile({
 *           source: new ol.source.OSM()
 *         })
 *       ],
 *       target: 'map'
 *     });
 *
 * The above snippet creates a map using a {@link ol.layer.Tile} to display
 * {@link ol.source.OSM} OSM data and render it to a DOM element with the
 * id `map`.
 *
 * The constructor places a viewport container (with CSS class name
 * `ol-viewport`) in the target element (see `getViewport()`), and then two
 * further elements within the viewport: one with CSS class name
 * `ol-overlaycontainer-stopevent` for controls and some overlays, and one with
 * CSS class name `ol-overlaycontainer` for other overlays (see the `stopEvent`
 * option of {@link ol.Overlay} for the difference). The map itself is placed in
 * a further element within the viewport.
 *
 * Layers are stored as a `ol.Collection` in layerGroups. A top-level group is
 * provided by the library. This is what is accessed by `getLayerGroup` and
 * `setLayerGroup`. Layers entered in the options are added to this group, and
 * `addLayer` and `removeLayer` change the layer collection in the group.
 * `getLayers` is a convenience function for `getLayerGroup().getLayers()`.
 * Note that `ol.layer.Group` is a subclass of `ol.layer.Base`, so layers
 * entered in the options or added with `addLayer` can be groups, which can
 * contain further groups, and so on.
 *
 * @constructor
 * @extends {ol.Object}
 * @param {olx.MapOptions} options Map options.
 * @fires ol.MapBrowserEvent
 * @fires ol.MapEvent
 * @fires ol.render.Event#postcompose
 * @fires ol.render.Event#precompose
 * @api
 */
ol.Map = function(options) {
 
  ol.Object.call(this);
 
  var optionsInternal = ol.Map.createOptionsInternal(options);
 
  /**
   * @type {boolean}
   * @private
   */
  this.loadTilesWhileAnimating_ =
      options.loadTilesWhileAnimating !== undefined ?
          options.loadTilesWhileAnimating : false;
 
  /**
   * @type {boolean}
   * @private
   */
  this.loadTilesWhileInteracting_ =
      options.loadTilesWhileInteracting !== undefined ?
          options.loadTilesWhileInteracting : false;
 
  /**
   * @private
   * @type {number}
   */
  this.pixelRatio_ = options.pixelRatio !== undefined ?
      options.pixelRatio : ol.has.DEVICE_PIXEL_RATIO;
 
  /**
   * @private
   * @type {Object.<string, string>}
   */
  this.logos_ = optionsInternal.logos;
 
  /**
   * @private
   * @type {number|undefined}
   */
  this.animationDelayKey_;
 
  /**
   * @private
   */
  this.animationDelay_ = function() {
    this.animationDelayKey_ = undefined;
    this.renderFrame_.call(this, Date.now());
  }.bind(this);
 
  /**
   * @private
   * @type {ol.Transform}
   */
  this.coordinateToPixelTransform_ = ol.transform.create();
 
  /**
   * @private
   * @type {ol.Transform}
   */
  this.pixelToCoordinateTransform_ = ol.transform.create();
 
  /**
   * @private
   * @type {number}
   */
  this.frameIndex_ = 0;
 
  /**
   * @private
   * @type {?olx.FrameState}
   */
  this.frameState_ = null;
 
  /**
   * The extent at the previous 'moveend' event.
   * @private
   * @type {ol.Extent}
   */
  this.previousExtent_ = ol.extent.createEmpty();
 
  /**
   * @private
   * @type {?ol.EventsKey}
   */
  this.viewPropertyListenerKey_ = null;
 
  /**
   * @private
   * @type {?ol.EventsKey}
   */
  this.viewChangeListenerKey_ = null;
 
  /**
   * @private
   * @type {Array.<ol.EventsKey>}
   */
  this.layerGroupPropertyListenerKeys_ = null;
 
  /**
   * @private
   * @type {Element}
   */
  this.viewport_ = document.createElement('DIV');
  this.viewport_.className = 'ol-viewport' + (ol.has.TOUCH ? ' ol-touch' : '');
  this.viewport_.style.position = 'relative';
  this.viewport_.style.overflow = 'hidden';
  this.viewport_.style.width = '100%';
  this.viewport_.style.height = '100%';
  // prevent page zoom on IE >= 10 browsers
  this.viewport_.style.msTouchAction = 'none';
  this.viewport_.style.touchAction = 'none';
 
  /**
   * @private
   * @type {!Element}
   */
  this.overlayContainer_ = document.createElement('DIV');
  this.overlayContainer_.className = 'ol-overlaycontainer';
  this.viewport_.appendChild(this.overlayContainer_);
 
  /**
   * @private
   * @type {!Element}
   */
  this.overlayContainerStopEvent_ = document.createElement('DIV');
  this.overlayContainerStopEvent_.className = 'ol-overlaycontainer-stopevent';
  var overlayEvents = [
    ol.events.EventType.CLICK,
    ol.events.EventType.DBLCLICK,
    ol.events.EventType.MOUSEDOWN,
    ol.events.EventType.TOUCHSTART,
    ol.events.EventType.MSPOINTERDOWN,
    ol.MapBrowserEventType.POINTERDOWN,
    ol.events.EventType.MOUSEWHEEL,
    ol.events.EventType.WHEEL
  ];
  for (var i = 0, ii = overlayEvents.length; i < ii; ++i) {
    ol.events.listen(this.overlayContainerStopEvent_, overlayEvents[i],
        ol.events.Event.stopPropagation);
  }
  this.viewport_.appendChild(this.overlayContainerStopEvent_);
 
  /**
   * @private
   * @type {ol.MapBrowserEventHandler}
   */
  this.mapBrowserEventHandler_ = new ol.MapBrowserEventHandler(this);
  for (var key in ol.MapBrowserEventType) {
    ol.events.listen(this.mapBrowserEventHandler_, ol.MapBrowserEventType[key],
        this.handleMapBrowserEvent, this);
  }
 
  /**
   * @private
   * @type {Element|Document}
   */
  this.keyboardEventTarget_ = optionsInternal.keyboardEventTarget;
 
  /**
   * @private
   * @type {Array.<ol.EventsKey>}
   */
  this.keyHandlerKeys_ = null;
 
  ol.events.listen(this.viewport_, ol.events.EventType.WHEEL,
      this.handleBrowserEvent, this);
  ol.events.listen(this.viewport_, ol.events.EventType.MOUSEWHEEL,
      this.handleBrowserEvent, this);
 
  /**
   * @type {ol.Collection.<ol.control.Control>}
   * @private
   */
  this.controls_ = optionsInternal.controls;
 
  /**
   * @type {ol.Collection.<ol.interaction.Interaction>}
   * @private
   */
  this.interactions_ = optionsInternal.interactions;
 
  /**
   * @type {ol.Collection.<ol.Overlay>}
   * @private
   */
  this.overlays_ = optionsInternal.overlays;
 
  /**
   * A lookup of overlays by id.
   * @private
   * @type {Object.<string, ol.Overlay>}
   */
  this.overlayIdIndex_ = {};
 
  /**
   * @type {ol.renderer.Map}
   * @private
   */
  this.renderer_ = new /** @type {Function} */ (optionsInternal.rendererConstructor)(this.viewport_, this);
 
  /**
   * @type {function(Event)|undefined}
   * @private
   */
  this.handleResize_;
 
  /**
   * @private
   * @type {ol.Coordinate}
   */
  this.focus_ = null;
 
  /**
   * @private
   * @type {Array.<ol.PostRenderFunction>}
   */
  this.postRenderFunctions_ = [];
 
  /**
   * @private
   * @type {ol.TileQueue}
   */
  this.tileQueue_ = new ol.TileQueue(
      this.getTilePriority.bind(this),
      this.handleTileChange_.bind(this));
 
  /**
   * Uids of features to skip at rendering time.
   * @type {Object.<string, boolean>}
   * @private
   */
  this.skippedFeatureUids_ = {};
 
  ol.events.listen(
      this, ol.Object.getChangeEventType(ol.MapProperty.LAYERGROUP),
      this.handleLayerGroupChanged_, this);
  ol.events.listen(this, ol.Object.getChangeEventType(ol.MapProperty.VIEW),
      this.handleViewChanged_, this);
  ol.events.listen(this, ol.Object.getChangeEventType(ol.MapProperty.SIZE),
      this.handleSizeChanged_, this);
  ol.events.listen(this, ol.Object.getChangeEventType(ol.MapProperty.TARGET),
      this.handleTargetChanged_, this);
 
  // setProperties will trigger the rendering of the map if the map
  // is "defined" already.
  this.setProperties(optionsInternal.values);
 
  this.controls_.forEach(
      /**
       * @param {ol.control.Control} control Control.
       * @this {ol.Map}
       */
      function(control) {
        control.setMap(this);
      }, this);
 
  ol.events.listen(this.controls_, ol.CollectionEventType.ADD,
      /**
       * @param {ol.Collection.Event} event Collection event.
       */
      function(event) {
        event.element.setMap(this);
      }, this);
 
  ol.events.listen(this.controls_, ol.CollectionEventType.REMOVE,
      /**
       * @param {ol.Collection.Event} event Collection event.
       */
      function(event) {
        event.element.setMap(null);
      }, this);
 
  this.interactions_.forEach(
      /**
       * @param {ol.interaction.Interaction} interaction Interaction.
       * @this {ol.Map}
       */
      function(interaction) {
        interaction.setMap(this);
      }, this);
 
  ol.events.listen(this.interactions_, ol.CollectionEventType.ADD,
      /**
       * @param {ol.Collection.Event} event Collection event.
       */
      function(event) {
        event.element.setMap(this);
      }, this);
 
  ol.events.listen(this.interactions_, ol.CollectionEventType.REMOVE,
      /**
       * @param {ol.Collection.Event} event Collection event.
       */
      function(event) {
        event.element.setMap(null);
      }, this);
 
  this.overlays_.forEach(this.addOverlayInternal_, this);
 
  ol.events.listen(this.overlays_, ol.CollectionEventType.ADD,
      /**
       * @param {ol.Collection.Event} event Collection event.
       */
      function(event) {
        this.addOverlayInternal_(/** @type {ol.Overlay} */ (event.element));
      }, this);
 
  ol.events.listen(this.overlays_, ol.CollectionEventType.REMOVE,
      /**
       * @param {ol.Collection.Event} event Collection event.
       */
      function(event) {
        var overlay = /** @type {ol.Overlay} */ (event.element);
        var id = overlay.getId();
        if (id !== undefined) {
          delete this.overlayIdIndex_[id.toString()];
        }
        event.element.setMap(null);
      }, this);
 
};
ol.inherits(ol.Map, ol.Object);
 
 
/**
 * Add the given control to the map.
 * @param {ol.control.Control} control Control.
 * @api
 */
ol.Map.prototype.addControl = function(control) {
  this.getControls().push(control);
};
 
 
/**
 * Add the given interaction to the map.
 * @param {ol.interaction.Interaction} interaction Interaction to add.
 * @api
 */
ol.Map.prototype.addInteraction = function(interaction) {
  this.getInteractions().push(interaction);
};
 
 
/**
 * Adds the given layer to the top of this map. If you want to add a layer
 * elsewhere in the stack, use `getLayers()` and the methods available on
 * {@link ol.Collection}.
 * @param {ol.layer.Base} layer Layer.
 * @api
 */
ol.Map.prototype.addLayer = function(layer) {
  var layers = this.getLayerGroup().getLayers();
  layers.push(layer);
};
 
 
/**
 * Add the given overlay to the map.
 * @param {ol.Overlay} overlay Overlay.
 * @api
 */
ol.Map.prototype.addOverlay = function(overlay) {
  this.getOverlays().push(overlay);
};
 
 
/**
 * This deals with map's overlay collection changes.
 * @param {ol.Overlay} overlay Overlay.
 * @private
 */
ol.Map.prototype.addOverlayInternal_ = function(overlay) {
  var id = overlay.getId();
  if (id !== undefined) {
    this.overlayIdIndex_[id.toString()] = overlay;
  }
  overlay.setMap(this);
};
 
 
/**
 *
 * @inheritDoc
 */
ol.Map.prototype.disposeInternal = function() {
  this.mapBrowserEventHandler_.dispose();
  this.renderer_.dispose();
  ol.events.unlisten(this.viewport_, ol.events.EventType.WHEEL,
      this.handleBrowserEvent, this);
  ol.events.unlisten(this.viewport_, ol.events.EventType.MOUSEWHEEL,
      this.handleBrowserEvent, this);
  if (this.handleResize_ !== undefined) {
    window.removeEventListener(ol.events.EventType.RESIZE,
        this.handleResize_, false);
    this.handleResize_ = undefined;
  }
  if (this.animationDelayKey_) {
    cancelAnimationFrame(this.animationDelayKey_);
    this.animationDelayKey_ = undefined;
  }
  this.setTarget(null);
  ol.Object.prototype.disposeInternal.call(this);
};
 
 
/**
 * Detect features that intersect a pixel on the viewport, and execute a
 * callback with each intersecting feature. Layers included in the detection can
 * be configured through `opt_layerFilter`.
 * @param {ol.Pixel} pixel Pixel.
 * @param {function(this: S, (ol.Feature|ol.render.Feature),
 *     ol.layer.Layer): T} callback Feature callback. The callback will be
 *     called with two arguments. The first argument is one
 *     {@link ol.Feature feature} or
 *     {@link ol.render.Feature render feature} at the pixel, the second is
 *     the {@link ol.layer.Layer layer} of the feature and will be null for
 *     unmanaged layers. To stop detection, callback functions can return a
 *     truthy value.
 * @param {olx.AtPixelOptions=} opt_options Optional options.
 * @return {T|undefined} Callback result, i.e. the return value of last
 * callback execution, or the first truthy callback return value.
 * @template S,T
 * @api
 */
ol.Map.prototype.forEachFeatureAtPixel = function(pixel, callback, opt_options) {
  if (!this.frameState_) {
    return;
  }
  var coordinate = this.getCoordinateFromPixel(pixel);
  opt_options = opt_options !== undefined ? opt_options : {};
  var hitTolerance = opt_options.hitTolerance !== undefined ?
    opt_options.hitTolerance * this.frameState_.pixelRatio : 0;
  var layerFilter = opt_options.layerFilter !== undefined ?
    opt_options.layerFilter : ol.functions.TRUE;
  return this.renderer_.forEachFeatureAtCoordinate(
      coordinate, this.frameState_, hitTolerance, callback, null,
      layerFilter, null);
};
 
 
/**
 * Detect layers that have a color value at a pixel on the viewport, and
 * execute a callback with each matching layer. Layers included in the
 * detection can be configured through `opt_layerFilter`.
 * @param {ol.Pixel} pixel Pixel.
 * @param {function(this: S, ol.layer.Layer, (Uint8ClampedArray|Uint8Array)): T} callback
 *     Layer callback. This callback will recieve two arguments: first is the
 *     {@link ol.layer.Layer layer}, second argument is an array representing
 *     [R, G, B, A] pixel values (0 - 255) and will be `null` for layer types
 *     that do not currently support this argument. To stop detection, callback
 *     functions can return a truthy value.
 * @param {S=} opt_this Value to use as `this` when executing `callback`.
 * @param {(function(this: U, ol.layer.Layer): boolean)=} opt_layerFilter Layer
 *     filter function. The filter function will receive one argument, the
 *     {@link ol.layer.Layer layer-candidate} and it should return a boolean
 *     value. Only layers which are visible and for which this function returns
 *     `true` will be tested for features. By default, all visible layers will
 *     be tested.
 * @param {U=} opt_this2 Value to use as `this` when executing `layerFilter`.
 * @return {T|undefined} Callback result, i.e. the return value of last
 * callback execution, or the first truthy callback return value.
 * @template S,T,U
 * @api
 */
ol.Map.prototype.forEachLayerAtPixel = function(pixel, callback, opt_this, opt_layerFilter, opt_this2) {
  if (!this.frameState_) {
    return;
  }
  var thisArg = opt_this !== undefined ? opt_this : null;
  var layerFilter = opt_layerFilter !== undefined ?
      opt_layerFilter : ol.functions.TRUE;
  var thisArg2 = opt_this2 !== undefined ? opt_this2 : null;
  return this.renderer_.forEachLayerAtPixel(
      pixel, this.frameState_, callback, thisArg,
      layerFilter, thisArg2);
};
 
 
/**
 * Detect if features intersect a pixel on the viewport. Layers included in the
 * detection can be configured through `opt_layerFilter`.
 * @param {ol.Pixel} pixel Pixel.
 * @param {olx.AtPixelOptions=} opt_options Optional options.
 * @return {boolean} Is there a feature at the given pixel?
 * @template U
 * @api
 */
ol.Map.prototype.hasFeatureAtPixel = function(pixel, opt_options) {
  if (!this.frameState_) {
    return false;
  }
  var coordinate = this.getCoordinateFromPixel(pixel);
  opt_options = opt_options !== undefined ? opt_options : {};
  var layerFilter = opt_options.layerFilter !== undefined ?
      opt_options.layerFilter : ol.functions.TRUE;
  var hitTolerance = opt_options.hitTolerance !== undefined ?
    opt_options.hitTolerance * this.frameState_.pixelRatio : 0;
  return this.renderer_.hasFeatureAtCoordinate(
      coordinate, this.frameState_, hitTolerance, layerFilter, null);
};
 
 
/**
 * Returns the coordinate in view projection for a browser event.
 * @param {Event} event Event.
 * @return {ol.Coordinate} Coordinate.
 * @api
 */
ol.Map.prototype.getEventCoordinate = function(event) {
  return this.getCoordinateFromPixel(this.getEventPixel(event));
};
 
 
/**
 * Returns the map pixel position for a browser event relative to the viewport.
 * @param {Event} event Event.
 * @return {ol.Pixel} Pixel.
 * @api
 */
ol.Map.prototype.getEventPixel = function(event) {
  var viewportPosition = this.viewport_.getBoundingClientRect();
  var eventPosition = event.changedTouches ? event.changedTouches[0] : event;
  return [
    eventPosition.clientX - viewportPosition.left,
    eventPosition.clientY - viewportPosition.top
  ];
};
 
 
/**
 * Get the target in which this map is rendered.
 * Note that this returns what is entered as an option or in setTarget:
 * if that was an element, it returns an element; if a string, it returns that.
 * @return {Element|string|undefined} The Element or id of the Element that the
 *     map is rendered in.
 * @observable
 * @api
 */
ol.Map.prototype.getTarget = function() {
  return /** @type {Element|string|undefined} */ (
      this.get(ol.MapProperty.TARGET));
};
 
 
/**
 * Get the DOM element into which this map is rendered. In contrast to
 * `getTarget` this method always return an `Element`, or `null` if the
 * map has no target.
 * @return {Element} The element that the map is rendered in.
 * @api
 */
ol.Map.prototype.getTargetElement = function() {
  var target = this.getTarget();
  if (target !== undefined) {
    return typeof target === 'string' ?
      document.getElementById(target) :
      target;
  } else {
    return null;
  }
};
 
 
/**
 * Get the coordinate for a given pixel.  This returns a coordinate in the
 * map view projection.
 * @param {ol.Pixel} pixel Pixel position in the map viewport.
 * @return {ol.Coordinate} The coordinate for the pixel position.
 * @api
 */
ol.Map.prototype.getCoordinateFromPixel = function(pixel) {
  var frameState = this.frameState_;
  if (!frameState) {
    return null;
  } else {
    return ol.transform.apply(frameState.pixelToCoordinateTransform, pixel.slice());
  }
};
 
 
/**
 * Get the map controls. Modifying this collection changes the controls
 * associated with the map.
 * @return {ol.Collection.<ol.control.Control>} Controls.
 * @api
 */
ol.Map.prototype.getControls = function() {
  return this.controls_;
};
 
 
/**
 * Get the map overlays. Modifying this collection changes the overlays
 * associated with the map.
 * @return {ol.Collection.<ol.Overlay>} Overlays.
 * @api
 */
ol.Map.prototype.getOverlays = function() {
  return this.overlays_;
};
 
 
/**
 * Get an overlay by its identifier (the value returned by overlay.getId()).
 * Note that the index treats string and numeric identifiers as the same. So
 * `map.getOverlayById(2)` will return an overlay with id `'2'` or `2`.
 * @param {string|number} id Overlay identifier.
 * @return {ol.Overlay} Overlay.
 * @api
 */
ol.Map.prototype.getOverlayById = function(id) {
  var overlay = this.overlayIdIndex_[id.toString()];
  return overlay !== undefined ? overlay : null;
};
 
 
/**
 * Get the map interactions. Modifying this collection changes the interactions
 * associated with the map.
 *
 * Interactions are used for e.g. pan, zoom and rotate.
 * @return {ol.Collection.<ol.interaction.Interaction>} Interactions.
 * @api
 */
ol.Map.prototype.getInteractions = function() {
  return this.interactions_;
};
 
 
/**
 * Get the layergroup associated with this map.
 * @return {ol.layer.Group} A layer group containing the layers in this map.
 * @observable
 * @api
 */
ol.Map.prototype.getLayerGroup = function() {
  return /** @type {ol.layer.Group} */ (this.get(ol.MapProperty.LAYERGROUP));
};
 
 
/**
 * Get the collection of layers associated with this map.
 * @return {!ol.Collection.<ol.layer.Base>} Layers.
 * @api
 */
ol.Map.prototype.getLayers = function() {
  var layers = this.getLayerGroup().getLayers();
  return layers;
};
 
 
/**
 * Get the pixel for a coordinate.  This takes a coordinate in the map view
 * projection and returns the corresponding pixel.
 * @param {ol.Coordinate} coordinate A map coordinate.
 * @return {ol.Pixel} A pixel position in the map viewport.
 * @api
 */
ol.Map.prototype.getPixelFromCoordinate = function(coordinate) {
  var frameState = this.frameState_;
  if (!frameState) {
    return null;
  } else {
    return ol.transform.apply(frameState.coordinateToPixelTransform,
        coordinate.slice(0, 2));
  }
};
 
 
/**
 * Get the map renderer.
 * @return {ol.renderer.Map} Renderer
 */
ol.Map.prototype.getRenderer = function() {
  return this.renderer_;
};
 
 
/**
 * Get the size of this map.
 * @return {ol.Size|undefined} The size in pixels of the map in the DOM.
 * @observable
 * @api
 */
ol.Map.prototype.getSize = function() {
  return /** @type {ol.Size|undefined} */ (this.get(ol.MapProperty.SIZE));
};
 
 
/**
 * Get the view associated with this map. A view manages properties such as
 * center and resolution.
 * @return {ol.View} The view that controls this map.
 * @observable
 * @api
 */
ol.Map.prototype.getView = function() {
  return /** @type {ol.View} */ (this.get(ol.MapProperty.VIEW));
};
 
 
/**
 * Get the element that serves as the map viewport.
 * @return {Element} Viewport.
 * @api
 */
ol.Map.prototype.getViewport = function() {
  return this.viewport_;
};
 
 
/**
 * Get the element that serves as the container for overlays.  Elements added to
 * this container will let mousedown and touchstart events through to the map,
 * so clicks and gestures on an overlay will trigger {@link ol.MapBrowserEvent}
 * events.
 * @return {!Element} The map's overlay container.
 */
ol.Map.prototype.getOverlayContainer = function() {
  return this.overlayContainer_;
};
 
 
/**
 * Get the element that serves as a container for overlays that don't allow
 * event propagation. Elements added to this container won't let mousedown and
 * touchstart events through to the map, so clicks and gestures on an overlay
 * don't trigger any {@link ol.MapBrowserEvent}.
 * @return {!Element} The map's overlay container that stops events.
 */
ol.Map.prototype.getOverlayContainerStopEvent = function() {
  return this.overlayContainerStopEvent_;
};
 
 
/**
 * @param {ol.Tile} tile Tile.
 * @param {string} tileSourceKey Tile source key.
 * @param {ol.Coordinate} tileCenter Tile center.
 * @param {number} tileResolution Tile resolution.
 * @return {number} Tile priority.
 */
ol.Map.prototype.getTilePriority = function(tile, tileSourceKey, tileCenter, tileResolution) {
  // Filter out tiles at higher zoom levels than the current zoom level, or that
  // are outside the visible extent.
  var frameState = this.frameState_;
  if (!frameState || !(tileSourceKey in frameState.wantedTiles)) {
    return ol.structs.PriorityQueue.DROP;
  }
  if (!frameState.wantedTiles[tileSourceKey][tile.getKey()]) {
    return ol.structs.PriorityQueue.DROP;
  }
  // Prioritize the highest zoom level tiles closest to the focus.
  // Tiles at higher zoom levels are prioritized using Math.log(tileResolution).
  // Within a zoom level, tiles are prioritized by the distance in pixels
  // between the center of the tile and the focus.  The factor of 65536 means
  // that the prioritization should behave as desired for tiles up to
  // 65536 * Math.log(2) = 45426 pixels from the focus.
  var deltaX = tileCenter[0] - frameState.focus[0];
  var deltaY = tileCenter[1] - frameState.focus[1];
  return 65536 * Math.log(tileResolution) +
      Math.sqrt(deltaX * deltaX + deltaY * deltaY) / tileResolution;
};
 
 
/**
 * @param {Event} browserEvent Browser event.
 * @param {string=} opt_type Type.
 */
ol.Map.prototype.handleBrowserEvent = function(browserEvent, opt_type) {
  var type = opt_type || browserEvent.type;
  var mapBrowserEvent = new ol.MapBrowserEvent(type, this, browserEvent);
  this.handleMapBrowserEvent(mapBrowserEvent);
};
 
 
/**
 * @param {ol.MapBrowserEvent} mapBrowserEvent The event to handle.
 */
ol.Map.prototype.handleMapBrowserEvent = function(mapBrowserEvent) {
  if (!this.frameState_) {
    // With no view defined, we cannot translate pixels into geographical
    // coordinates so interactions cannot be used.
    return;
  }
  this.focus_ = mapBrowserEvent.coordinate;
  mapBrowserEvent.frameState = this.frameState_;
  var interactionsArray = this.getInteractions().getArray();
  var i;
  if (this.dispatchEvent(mapBrowserEvent) !== false) {
    for (i = interactionsArray.length - 1; i >= 0; i--) {
      var interaction = interactionsArray[i];
      if (!interaction.getActive()) {
        continue;
      }
      var cont = interaction.handleEvent(mapBrowserEvent);
      if (!cont) {
        break;
      }
    }
  }
};
 
 
/**
 * @protected
 */
ol.Map.prototype.handlePostRender = function() {
 
  var frameState = this.frameState_;
 
  // Manage the tile queue
  // Image loads are expensive and a limited resource, so try to use them
  // efficiently:
  // * When the view is static we allow a large number of parallel tile loads
  //   to complete the frame as quickly as possible.
  // * When animating or interacting, image loads can cause janks, so we reduce
  //   the maximum number of loads per frame and limit the number of parallel
  //   tile loads to remain reactive to view changes and to reduce the chance of
  //   loading tiles that will quickly disappear from view.
  var tileQueue = this.tileQueue_;
  if (!tileQueue.isEmpty()) {
    var maxTotalLoading = 16;
    var maxNewLoads = maxTotalLoading;
    if (frameState) {
      var hints = frameState.viewHints;
      if (hints[ol.ViewHint.ANIMATING]) {
        maxTotalLoading = this.loadTilesWhileAnimating_ ? 8 : 0;
        maxNewLoads = 2;
      }
      if (hints[ol.ViewHint.INTERACTING]) {
        maxTotalLoading = this.loadTilesWhileInteracting_ ? 8 : 0;
        maxNewLoads = 2;
      }
    }
    if (tileQueue.getTilesLoading() < maxTotalLoading) {
      tileQueue.reprioritize(); // FIXME only call if view has changed
      tileQueue.loadMoreTiles(maxTotalLoading, maxNewLoads);
    }
  }
 
  var postRenderFunctions = this.postRenderFunctions_;
  var i, ii;
  for (i = 0, ii = postRenderFunctions.length; i < ii; ++i) {
    postRenderFunctions[i](this, frameState);
  }
  postRenderFunctions.length = 0;
};
 
 
/**
 * @private
 */
ol.Map.prototype.handleSizeChanged_ = function() {
  this.render();
};
 
 
/**
 * @private
 */
ol.Map.prototype.handleTargetChanged_ = function() {
  // target may be undefined, null, a string or an Element.
  // If it's a string we convert it to an Element before proceeding.
  // If it's not now an Element we remove the viewport from the DOM.
  // If it's an Element we append the viewport element to it.
 
  var targetElement;
  if (this.getTarget()) {
    targetElement = this.getTargetElement();
  }
 
  if (this.keyHandlerKeys_) {
    for (var i = 0, ii = this.keyHandlerKeys_.length; i < ii; ++i) {
      ol.events.unlistenByKey(this.keyHandlerKeys_[i]);
    }
    this.keyHandlerKeys_ = null;
  }
 
  if (!targetElement) {
    ol.dom.removeNode(this.viewport_);
    if (this.handleResize_ !== undefined) {
      window.removeEventListener(ol.events.EventType.RESIZE,
          this.handleResize_, false);
      this.handleResize_ = undefined;
    }
  } else {
    targetElement.appendChild(this.viewport_);
 
    var keyboardEventTarget = !this.keyboardEventTarget_ ?
        targetElement : this.keyboardEventTarget_;
    this.keyHandlerKeys_ = [
      ol.events.listen(keyboardEventTarget, ol.events.EventType.KEYDOWN,
          this.handleBrowserEvent, this),
      ol.events.listen(keyboardEventTarget, ol.events.EventType.KEYPRESS,
          this.handleBrowserEvent, this)
    ];
 
    if (!this.handleResize_) {
      this.handleResize_ = this.updateSize.bind(this);
      window.addEventListener(ol.events.EventType.RESIZE,
          this.handleResize_, false);
    }
  }
 
  this.updateSize();
  // updateSize calls setSize, so no need to call this.render
  // ourselves here.
};
 
 
/**
 * @private
 */
ol.Map.prototype.handleTileChange_ = function() {
  this.render();
};
 
 
/**
 * @private
 */
ol.Map.prototype.handleViewPropertyChanged_ = function() {
  this.render();
};
 
 
/**
 * @private
 */
ol.Map.prototype.handleViewChanged_ = function() {
  if (this.viewPropertyListenerKey_) {
    ol.events.unlistenByKey(this.viewPropertyListenerKey_);
    this.viewPropertyListenerKey_ = null;
  }
  if (this.viewChangeListenerKey_) {
    ol.events.unlistenByKey(this.viewChangeListenerKey_);
    this.viewChangeListenerKey_ = null;
  }
  var view = this.getView();
  if (view) {
    this.viewport_.setAttribute('data-view', ol.getUid(view));
    this.viewPropertyListenerKey_ = ol.events.listen(
        view, ol.ObjectEventType.PROPERTYCHANGE,
        this.handleViewPropertyChanged_, this);
    this.viewChangeListenerKey_ = ol.events.listen(
        view, ol.events.EventType.CHANGE,
        this.handleViewPropertyChanged_, this);
  }
  this.render();
};
 
 
/**
 * @private
 */
ol.Map.prototype.handleLayerGroupChanged_ = function() {
  if (this.layerGroupPropertyListenerKeys_) {
    this.layerGroupPropertyListenerKeys_.forEach(ol.events.unlistenByKey);
    this.layerGroupPropertyListenerKeys_ = null;
  }
  var layerGroup = this.getLayerGroup();
  if (layerGroup) {
    this.layerGroupPropertyListenerKeys_ = [
      ol.events.listen(
          layerGroup, ol.ObjectEventType.PROPERTYCHANGE,
          this.render, this),
      ol.events.listen(
          layerGroup, ol.events.EventType.CHANGE,
          this.render, this)
    ];
  }
  this.render();
};
 
 
/**
 * @return {boolean} Is rendered.
 */
ol.Map.prototype.isRendered = function() {
  return !!this.frameState_;
};
 
 
/**
 * Requests an immediate render in a synchronous manner.
 * @api
 */
ol.Map.prototype.renderSync = function() {
  if (this.animationDelayKey_) {
    cancelAnimationFrame(this.animationDelayKey_);
  }
  this.animationDelay_();
};
 
 
/**
 * Request a map rendering (at the next animation frame).
 * @api
 */
ol.Map.prototype.render = function() {
  if (this.animationDelayKey_ === undefined) {
    this.animationDelayKey_ = requestAnimationFrame(
        this.animationDelay_);
  }
};
 
 
/**
 * Remove the given control from the map.
 * @param {ol.control.Control} control Control.
 * @return {ol.control.Control|undefined} The removed control (or undefined
 *     if the control was not found).
 * @api
 */
ol.Map.prototype.removeControl = function(control) {
  return this.getControls().remove(control);
};
 
 
/**
 * Remove the given interaction from the map.
 * @param {ol.interaction.Interaction} interaction Interaction to remove.
 * @return {ol.interaction.Interaction|undefined} The removed interaction (or
 *     undefined if the interaction was not found).
 * @api
 */
ol.Map.prototype.removeInteraction = function(interaction) {
  return this.getInteractions().remove(interaction);
};
 
 
/**
 * Removes the given layer from the map.
 * @param {ol.layer.Base} layer Layer.
 * @return {ol.layer.Base|undefined} The removed layer (or undefined if the
 *     layer was not found).
 * @api
 */
ol.Map.prototype.removeLayer = function(layer) {
  var layers = this.getLayerGroup().getLayers();
  return layers.remove(layer);
};
 
 
/**
 * Remove the given overlay from the map.
 * @param {ol.Overlay} overlay Overlay.
 * @return {ol.Overlay|undefined} The removed overlay (or undefined
 *     if the overlay was not found).
 * @api
 */
ol.Map.prototype.removeOverlay = function(overlay) {
  return this.getOverlays().remove(overlay);
};
 
 
/**
 * @param {number} time Time.
 * @private
 */
ol.Map.prototype.renderFrame_ = function(time) {
  var i, ii, viewState;
 
  var size = this.getSize();
  var view = this.getView();
  var extent = ol.extent.createEmpty();
  /** @type {?olx.FrameState} */
  var frameState = null;
  if (size !== undefined && ol.size.hasArea(size) && view && view.isDef()) {
    var viewHints = view.getHints(this.frameState_ ? this.frameState_.viewHints : undefined);
    var layerStatesArray = this.getLayerGroup().getLayerStatesArray();
    var layerStates = {};
    for (i = 0, ii = layerStatesArray.length; i < ii; ++i) {
      layerStates[ol.getUid(layerStatesArray[i].layer)] = layerStatesArray[i];
    }
    viewState = view.getState();
    frameState = /** @type {olx.FrameState} */ ({
      animate: false,
      attributions: {},
      coordinateToPixelTransform: this.coordinateToPixelTransform_,
      extent: extent,
      focus: !this.focus_ ? viewState.center : this.focus_,
      index: this.frameIndex_++,
      layerStates: layerStates,
      layerStatesArray: layerStatesArray,
      logos: ol.obj.assign({}, this.logos_),
      pixelRatio: this.pixelRatio_,
      pixelToCoordinateTransform: this.pixelToCoordinateTransform_,
      postRenderFunctions: [],
      size: size,
      skippedFeatureUids: this.skippedFeatureUids_,
      tileQueue: this.tileQueue_,
      time: time,
      usedTiles: {},
      viewState: viewState,
      viewHints: viewHints,
      wantedTiles: {}
    });
  }
 
  if (frameState) {
    frameState.extent = ol.extent.getForViewAndSize(viewState.center,
        viewState.resolution, viewState.rotation, frameState.size, extent);
  }
 
  this.frameState_ = frameState;
  this.renderer_.renderFrame(frameState);
 
  if (frameState) {
    if (frameState.animate) {
      this.render();
    }
    Array.prototype.push.apply(
        this.postRenderFunctions_, frameState.postRenderFunctions);
 
    var idle = !frameState.viewHints[ol.ViewHint.ANIMATING] &&
        !frameState.viewHints[ol.ViewHint.INTERACTING] &&
        !ol.extent.equals(frameState.extent, this.previousExtent_);
 
    if (idle) {
      this.dispatchEvent(
          new ol.MapEvent(ol.MapEventType.MOVEEND, this, frameState));
      ol.extent.clone(frameState.extent, this.previousExtent_);
    }
  }
 
  this.dispatchEvent(
      new ol.MapEvent(ol.MapEventType.POSTRENDER, this, frameState));
 
  setTimeout(this.handlePostRender.bind(this), 0);
 
};
 
 
/**
 * Sets the layergroup of this map.
 * @param {ol.layer.Group} layerGroup A layer group containing the layers in
 *     this map.
 * @observable
 * @api
 */
ol.Map.prototype.setLayerGroup = function(layerGroup) {
  this.set(ol.MapProperty.LAYERGROUP, layerGroup);
};
 
 
/**
 * Set the size of this map.
 * @param {ol.Size|undefined} size The size in pixels of the map in the DOM.
 * @observable
 * @api
 */
ol.Map.prototype.setSize = function(size) {
  this.set(ol.MapProperty.SIZE, size);
};
 
 
/**
 * Set the target element to render this map into.
 * @param {Element|string|undefined} target The Element or id of the Element
 *     that the map is rendered in.
 * @observable
 * @api
 */
ol.Map.prototype.setTarget = function(target) {
  this.set(ol.MapProperty.TARGET, target);
};
 
 
/**
 * Set the view for this map.
 * @param {ol.View} view The view that controls this map.
 * @observable
 * @api
 */
ol.Map.prototype.setView = function(view) {
  this.set(ol.MapProperty.VIEW, view);
};
 
 
/**
 * @param {ol.Feature} feature Feature.
 */
ol.Map.prototype.skipFeature = function(feature) {
  var featureUid = ol.getUid(feature).toString();
  this.skippedFeatureUids_[featureUid] = true;
  this.render();
};
 
 
/**
 * Force a recalculation of the map viewport size.  This should be called when
 * third-party code changes the size of the map viewport.
 * @api
 */
ol.Map.prototype.updateSize = function() {
  var targetElement = this.getTargetElement();
 
  if (!targetElement) {
    this.setSize(undefined);
  } else {
    var computedStyle = getComputedStyle(targetElement);
    this.setSize([
      targetElement.offsetWidth -
          parseFloat(computedStyle['borderLeftWidth']) -
          parseFloat(computedStyle['paddingLeft']) -
          parseFloat(computedStyle['paddingRight']) -
          parseFloat(computedStyle['borderRightWidth']),
      targetElement.offsetHeight -
          parseFloat(computedStyle['borderTopWidth']) -
          parseFloat(computedStyle['paddingTop']) -
          parseFloat(computedStyle['paddingBottom']) -
          parseFloat(computedStyle['borderBottomWidth'])
    ]);
  }
};
 
 
/**
 * @param {ol.Feature} feature Feature.
 */
ol.Map.prototype.unskipFeature = function(feature) {
  var featureUid = ol.getUid(feature).toString();
  delete this.skippedFeatureUids_[featureUid];
  this.render();
};
 
 
/**
 * @param {olx.MapOptions} options Map options.
 * @return {ol.MapOptionsInternal} Internal map options.
 */
ol.Map.createOptionsInternal = function(options) {
 
  /**
   * @type {Element|Document}
   */
  var keyboardEventTarget = null;
  if (options.keyboardEventTarget !== undefined) {
    keyboardEventTarget = typeof options.keyboardEventTarget === 'string' ?
        document.getElementById(options.keyboardEventTarget) :
        options.keyboardEventTarget;
  }
 
  /**
   * @type {Object.<string, *>}
   */
  var values = {};
 
  var logos = {};
  if (options.logo === undefined ||
      (typeof options.logo === 'boolean' && options.logo)) {
    logos[ol.OL_LOGO_URL] = ol.OL_URL;
  } else {
    var logo = options.logo;
    if (typeof logo === 'string') {
      logos[logo] = '';
    } else if (logo instanceof HTMLElement) {
      logos[ol.getUid(logo).toString()] = logo;
    } else if (logo) {
      ol.asserts.assert(typeof logo.href == 'string', 44); // `logo.href` should be a string.
      ol.asserts.assert(typeof logo.src == 'string', 45); // `logo.src` should be a string.
      logos[logo.src] = logo.href;
    }
  }
 
  var layerGroup = (options.layers instanceof ol.layer.Group) ?
      options.layers : new ol.layer.Group({layers: options.layers});
  values[ol.MapProperty.LAYERGROUP] = layerGroup;
 
  values[ol.MapProperty.TARGET] = options.target;
 
  values[ol.MapProperty.VIEW] = options.view !== undefined ?
      options.view : new ol.View();
 
  /**
   * @type {function(new: ol.renderer.Map, Element, ol.Map)}
   */
  var rendererConstructor = ol.renderer.Map;
 
  /**
   * @type {Array.<ol.renderer.Type>}
   */
  var rendererTypes;
  if (options.renderer !== undefined) {
    if (Array.isArray(options.renderer)) {
      rendererTypes = options.renderer;
    } else if (typeof options.renderer === 'string') {
      rendererTypes = [options.renderer];
    } else {
      ol.asserts.assert(false, 46); // Incorrect format for `renderer` option
    }
    if (rendererTypes.indexOf(/** @type {ol.renderer.Type} */ ('dom')) >= 0) {
      rendererTypes = rendererTypes.concat(ol.DEFAULT_RENDERER_TYPES);
    }
  } else {
    rendererTypes = ol.DEFAULT_RENDERER_TYPES;
  }
 
  var i, ii;
  for (i = 0, ii = rendererTypes.length; i < ii; ++i) {
    /** @type {ol.renderer.Type} */
    var rendererType = rendererTypes[i];
    if (ol.ENABLE_CANVAS && rendererType == ol.renderer.Type.CANVAS) {
      if (ol.has.CANVAS) {
        rendererConstructor = ol.renderer.canvas.Map;
        break;
      }
    } else if (ol.ENABLE_WEBGL && rendererType == ol.renderer.Type.WEBGL) {
      if (ol.has.WEBGL) {
        rendererConstructor = ol.renderer.webgl.Map;
        break;
      }
    }
  }
 
  var controls;
  if (options.controls !== undefined) {
    if (Array.isArray(options.controls)) {
      controls = new ol.Collection(options.controls.slice());
    } else {
      ol.asserts.assert(options.controls instanceof ol.Collection,
          47); // Expected `controls` to be an array or an `ol.Collection`
      controls = options.controls;
    }
  } else {
    controls = ol.control.defaults();
  }
 
  var interactions;
  if (options.interactions !== undefined) {
    if (Array.isArray(options.interactions)) {
      interactions = new ol.Collection(options.interactions.slice());
    } else {
      ol.asserts.assert(options.interactions instanceof ol.Collection,
          48); // Expected `interactions` to be an array or an `ol.Collection`
      interactions = options.interactions;
    }
  } else {
    interactions = ol.interaction.defaults();
  }
 
  var overlays;
  if (options.overlays !== undefined) {
    if (Array.isArray(options.overlays)) {
      overlays = new ol.Collection(options.overlays.slice());
    } else {
      ol.asserts.assert(options.overlays instanceof ol.Collection,
          49); // Expected `overlays` to be an array or an `ol.Collection`
      overlays = options.overlays;
    }
  } else {
    overlays = new ol.Collection();
  }
 
  return {
    controls: controls,
    interactions: interactions,
    keyboardEventTarget: keyboardEventTarget,
    logos: logos,
    overlays: overlays,
    rendererConstructor: rendererConstructor,
    values: values
  };
 
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapbrowserevent.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapbrowserevent.js

Statements: 6.25% (1 / 16)      Branches: 0% (0 / 2)      Functions: 0% (0 / 3)      Lines: 6.25% (1 / 16)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 842                                                                                                                                                                      
goog.provide('ol.MapBrowserEvent');
 
goog.require('ol');
goog.require('ol.MapEvent');
 
 
/**
 * @classdesc
 * Events emitted as map browser events are instances of this type.
 * See {@link ol.Map} for which events trigger a map browser event.
 *
 * @constructor
 * @extends {ol.MapEvent}
 * @implements {oli.MapBrowserEvent}
 * @param {string} type Event type.
 * @param {ol.Map} map Map.
 * @param {Event} browserEvent Browser event.
 * @param {boolean=} opt_dragging Is the map currently being dragged?
 * @param {?olx.FrameState=} opt_frameState Frame state.
 */
ol.MapBrowserEvent = function(type, map, browserEvent, opt_dragging,
    opt_frameState) {
 
  ol.MapEvent.call(this, type, map, opt_frameState);
 
  /**
   * The original browser event.
   * @const
   * @type {Event}
   * @api
   */
  this.originalEvent = browserEvent;
 
  /**
   * The map pixel relative to the viewport corresponding to the original browser event.
   * @type {ol.Pixel}
   * @api
   */
  this.pixel = map.getEventPixel(browserEvent);
 
  /**
   * The coordinate in view projection corresponding to the original browser event.
   * @type {ol.Coordinate}
   * @api
   */
  this.coordinate = map.getCoordinateFromPixel(this.pixel);
 
  /**
   * Indicates if the map is currently being dragged. Only set for
   * `POINTERDRAG` and `POINTERMOVE` events. Default is `false`.
   *
   * @type {boolean}
   * @api
   */
  this.dragging = opt_dragging !== undefined ? opt_dragging : false;
 
};
ol.inherits(ol.MapBrowserEvent, ol.MapEvent);
 
 
/**
 * Prevents the default browser action.
 * @see https://developer.mozilla.org/en-US/docs/Web/API/event.preventDefault
 * @override
 * @api
 */
ol.MapBrowserEvent.prototype.preventDefault = function() {
  ol.MapEvent.prototype.preventDefault.call(this);
  this.originalEvent.preventDefault();
};
 
 
/**
 * Prevents further propagation of the current event.
 * @see https://developer.mozilla.org/en-US/docs/Web/API/event.stopPropagation
 * @override
 * @api
 */
ol.MapBrowserEvent.prototype.stopPropagation = function() {
  ol.MapEvent.prototype.stopPropagation.call(this);
  this.originalEvent.stopPropagation();
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapbrowsereventhandler.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapbrowsereventhandler.js

Statements: 1.09% (1 / 92)      Branches: 0% (0 / 30)      Functions: 0% (0 / 11)      Lines: 1.09% (1 / 92)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 3162                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      
goog.provide('ol.MapBrowserEventHandler');
 
goog.require('ol');
goog.require('ol.MapBrowserEventType');
goog.require('ol.MapBrowserPointerEvent');
goog.require('ol.events');
goog.require('ol.events.EventTarget');
goog.require('ol.pointer.EventType');
goog.require('ol.pointer.PointerEventHandler');
 
 
/**
 * @param {ol.Map} map The map with the viewport to listen to events on.
 * @constructor
 * @extends {ol.events.EventTarget}
 */
ol.MapBrowserEventHandler = function(map) {
 
  ol.events.EventTarget.call(this);
 
  /**
   * This is the element that we will listen to the real events on.
   * @type {ol.Map}
   * @private
   */
  this.map_ = map;
 
  /**
   * @type {number}
   * @private
   */
  this.clickTimeoutId_ = 0;
 
  /**
   * @type {boolean}
   * @private
   */
  this.dragging_ = false;
 
  /**
   * @type {!Array.<ol.EventsKey>}
   * @private
   */
  this.dragListenerKeys_ = [];
 
  /**
   * The most recent "down" type event (or null if none have occurred).
   * Set on pointerdown.
   * @type {ol.pointer.PointerEvent}
   * @private
   */
  this.down_ = null;
 
  var element = this.map_.getViewport();
 
  /**
   * @type {number}
   * @private
   */
  this.activePointers_ = 0;
 
  /**
   * @type {!Object.<number, boolean>}
   * @private
   */
  this.trackedTouches_ = {};
 
  /**
   * Event handler which generates pointer events for
   * the viewport element.
   *
   * @type {ol.pointer.PointerEventHandler}
   * @private
   */
  this.pointerEventHandler_ = new ol.pointer.PointerEventHandler(element);
 
  /**
   * Event handler which generates pointer events for
   * the document (used when dragging).
   *
   * @type {ol.pointer.PointerEventHandler}
   * @private
   */
  this.documentPointerEventHandler_ = null;
 
  /**
   * @type {?ol.EventsKey}
   * @private
   */
  this.pointerdownListenerKey_ = ol.events.listen(this.pointerEventHandler_,
      ol.pointer.EventType.POINTERDOWN,
      this.handlePointerDown_, this);
 
  /**
   * @type {?ol.EventsKey}
   * @private
   */
  this.relayedListenerKey_ = ol.events.listen(this.pointerEventHandler_,
      ol.pointer.EventType.POINTERMOVE,
      this.relayEvent_, this);
 
};
ol.inherits(ol.MapBrowserEventHandler, ol.events.EventTarget);
 
 
/**
 * @param {ol.pointer.PointerEvent} pointerEvent Pointer event.
 * @private
 */
ol.MapBrowserEventHandler.prototype.emulateClick_ = function(pointerEvent) {
  var newEvent = new ol.MapBrowserPointerEvent(
      ol.MapBrowserEventType.CLICK, this.map_, pointerEvent);
  this.dispatchEvent(newEvent);
  if (this.clickTimeoutId_ !== 0) {
    // double-click
    clearTimeout(this.clickTimeoutId_);
    this.clickTimeoutId_ = 0;
    newEvent = new ol.MapBrowserPointerEvent(
        ol.MapBrowserEventType.DBLCLICK, this.map_, pointerEvent);
    this.dispatchEvent(newEvent);
  } else {
    // click
    this.clickTimeoutId_ = setTimeout(function() {
      this.clickTimeoutId_ = 0;
      var newEvent = new ol.MapBrowserPointerEvent(
          ol.MapBrowserEventType.SINGLECLICK, this.map_, pointerEvent);
      this.dispatchEvent(newEvent);
    }.bind(this), 250);
  }
};
 
 
/**
 * Keeps track on how many pointers are currently active.
 *
 * @param {ol.pointer.PointerEvent} pointerEvent Pointer event.
 * @private
 */
ol.MapBrowserEventHandler.prototype.updateActivePointers_ = function(pointerEvent) {
  var event = pointerEvent;
 
  if (event.type == ol.MapBrowserEventType.POINTERUP ||
      event.type == ol.MapBrowserEventType.POINTERCANCEL) {
    delete this.trackedTouches_[event.pointerId];
  } else if (event.type == ol.MapBrowserEventType.POINTERDOWN) {
    this.trackedTouches_[event.pointerId] = true;
  }
  this.activePointers_ = Object.keys(this.trackedTouches_).length;
};
 
 
/**
 * @param {ol.pointer.PointerEvent} pointerEvent Pointer event.
 * @private
 */
ol.MapBrowserEventHandler.prototype.handlePointerUp_ = function(pointerEvent) {
  this.updateActivePointers_(pointerEvent);
  var newEvent = new ol.MapBrowserPointerEvent(
     ol.MapBrowserEventType.POINTERUP, this.map_, pointerEvent);
  this.dispatchEvent(newEvent);
 
 // We emulate click events on left mouse button click, touch contact, and pen
 // contact. isMouseActionButton returns true in these cases (evt.button is set
 // to 0).
 // See http://www.w3.org/TR/pointerevents/#button-states
  if (!this.dragging_ && this.isMouseActionButton_(pointerEvent)) {
    this.emulateClick_(this.down_);
  }
 
  if (this.activePointers_ === 0) {
    this.dragListenerKeys_.forEach(ol.events.unlistenByKey);
    this.dragListenerKeys_.length = 0;
    this.dragging_ = false;
    this.down_ = null;
    this.documentPointerEventHandler_.dispose();
    this.documentPointerEventHandler_ = null;
  }
};
 
 
/**
 * @param {ol.pointer.PointerEvent} pointerEvent Pointer event.
 * @return {boolean} If the left mouse button was pressed.
 * @private
 */
ol.MapBrowserEventHandler.prototype.isMouseActionButton_ = function(pointerEvent) {
  return pointerEvent.button === 0;
};
 
 
/**
 * @param {ol.pointer.PointerEvent} pointerEvent Pointer event.
 * @private
 */
ol.MapBrowserEventHandler.prototype.handlePointerDown_ = function(pointerEvent) {
  this.updateActivePointers_(pointerEvent);
  var newEvent = new ol.MapBrowserPointerEvent(
      ol.MapBrowserEventType.POINTERDOWN, this.map_, pointerEvent);
  this.dispatchEvent(newEvent);
 
  this.down_ = pointerEvent;
 
  if (this.dragListenerKeys_.length === 0) {
    /* Set up a pointer event handler on the `document`,
     * which is required when the pointer is moved outside
     * the viewport when dragging.
     */
    this.documentPointerEventHandler_ =
        new ol.pointer.PointerEventHandler(document);
 
    this.dragListenerKeys_.push(
      ol.events.listen(this.documentPointerEventHandler_,
          ol.MapBrowserEventType.POINTERMOVE,
          this.handlePointerMove_, this),
      ol.events.listen(this.documentPointerEventHandler_,
          ol.MapBrowserEventType.POINTERUP,
          this.handlePointerUp_, this),
      /* Note that the listener for `pointercancel is set up on
       * `pointerEventHandler_` and not `documentPointerEventHandler_` like
       * the `pointerup` and `pointermove` listeners.
       *
       * The reason for this is the following: `TouchSource.vacuumTouches_()`
       * issues `pointercancel` events, when there was no `touchend` for a
       * `touchstart`. Now, let's say a first `touchstart` is registered on
       * `pointerEventHandler_`. The `documentPointerEventHandler_` is set up.
       * But `documentPointerEventHandler_` doesn't know about the first
       * `touchstart`. If there is no `touchend` for the `touchstart`, we can
       * only receive a `touchcancel` from `pointerEventHandler_`, because it is
       * only registered there.
       */
      ol.events.listen(this.pointerEventHandler_,
          ol.MapBrowserEventType.POINTERCANCEL,
          this.handlePointerUp_, this)
    );
  }
};
 
 
/**
 * @param {ol.pointer.PointerEvent} pointerEvent Pointer event.
 * @private
 */
ol.MapBrowserEventHandler.prototype.handlePointerMove_ = function(pointerEvent) {
  // Fix IE10 on windows Surface : When you tap the tablet, it triggers
  // multiple pointermove events between pointerdown and pointerup with
  // the exact same coordinates of the pointerdown event. To avoid a
  // 'false' touchmove event to be dispatched , we test if the pointer
  // effectively moved.
  if (this.isMoving_(pointerEvent)) {
    this.dragging_ = true;
    var newEvent = new ol.MapBrowserPointerEvent(
        ol.MapBrowserEventType.POINTERDRAG, this.map_, pointerEvent,
        this.dragging_);
    this.dispatchEvent(newEvent);
  }
 
  // Some native android browser triggers mousemove events during small period
  // of time. See: https://code.google.com/p/android/issues/detail?id=5491 or
  // https://code.google.com/p/android/issues/detail?id=19827
  // ex: Galaxy Tab P3110 + Android 4.1.1
  pointerEvent.preventDefault();
};
 
 
/**
 * Wrap and relay a pointer event.  Note that this requires that the type
 * string for the MapBrowserPointerEvent matches the PointerEvent type.
 * @param {ol.pointer.PointerEvent} pointerEvent Pointer event.
 * @private
 */
ol.MapBrowserEventHandler.prototype.relayEvent_ = function(pointerEvent) {
  var dragging = !!(this.down_ && this.isMoving_(pointerEvent));
  this.dispatchEvent(new ol.MapBrowserPointerEvent(
      pointerEvent.type, this.map_, pointerEvent, dragging));
};
 
 
/**
 * @param {ol.pointer.PointerEvent} pointerEvent Pointer event.
 * @return {boolean} Is moving.
 * @private
 */
ol.MapBrowserEventHandler.prototype.isMoving_ = function(pointerEvent) {
  return pointerEvent.clientX != this.down_.clientX ||
      pointerEvent.clientY != this.down_.clientY;
};
 
 
/**
 * @inheritDoc
 */
ol.MapBrowserEventHandler.prototype.disposeInternal = function() {
  if (this.relayedListenerKey_) {
    ol.events.unlistenByKey(this.relayedListenerKey_);
    this.relayedListenerKey_ = null;
  }
  if (this.pointerdownListenerKey_) {
    ol.events.unlistenByKey(this.pointerdownListenerKey_);
    this.pointerdownListenerKey_ = null;
  }
 
  this.dragListenerKeys_.forEach(ol.events.unlistenByKey);
  this.dragListenerKeys_.length = 0;
 
  if (this.documentPointerEventHandler_) {
    this.documentPointerEventHandler_.dispose();
    this.documentPointerEventHandler_ = null;
  }
  if (this.pointerEventHandler_) {
    this.pointerEventHandler_.dispose();
    this.pointerEventHandler_ = null;
  }
  ol.events.EventTarget.prototype.disposeInternal.call(this);
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapbrowsereventtype.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapbrowsereventtype.js

Statements: 33.33% (1 / 3)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 33.33% (1 / 3)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 582                                                                                                                  
goog.provide('ol.MapBrowserEventType');
 
goog.require('ol.events.EventType');
 
 
/**
 * Constants for event names.
 * @enum {string}
 */
ol.MapBrowserEventType = {
 
  /**
   * A true single click with no dragging and no double click. Note that this
   * event is delayed by 250 ms to ensure that it is not a double click.
   * @event ol.MapBrowserEvent#singleclick
   * @api
   */
  SINGLECLICK: 'singleclick',
 
  /**
   * A click with no dragging. A double click will fire two of this.
   * @event ol.MapBrowserEvent#click
   * @api
   */
  CLICK: ol.events.EventType.CLICK,
 
  /**
   * A true double click, with no dragging.
   * @event ol.MapBrowserEvent#dblclick
   * @api
   */
  DBLCLICK: ol.events.EventType.DBLCLICK,
 
  /**
   * Triggered when a pointer is dragged.
   * @event ol.MapBrowserEvent#pointerdrag
   * @api
   */
  POINTERDRAG: 'pointerdrag',
 
  /**
   * Triggered when a pointer is moved. Note that on touch devices this is
   * triggered when the map is panned, so is not the same as mousemove.
   * @event ol.MapBrowserEvent#pointermove
   * @api
   */
  POINTERMOVE: 'pointermove',
 
  POINTERDOWN: 'pointerdown',
  POINTERUP: 'pointerup',
  POINTEROVER: 'pointerover',
  POINTEROUT: 'pointerout',
  POINTERENTER: 'pointerenter',
  POINTERLEAVE: 'pointerleave',
  POINTERCANCEL: 'pointercancel'
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapbrowserpointerevent.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapbrowserpointerevent.js

Statements: 14.29% (1 / 7)      Branches: 100% (0 / 0)      Functions: 0% (0 / 1)      Lines: 14.29% (1 / 7)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 312                                                            
goog.provide('ol.MapBrowserPointerEvent');
 
goog.require('ol');
goog.require('ol.MapBrowserEvent');
 
 
/**
 * @constructor
 * @extends {ol.MapBrowserEvent}
 * @param {string} type Event type.
 * @param {ol.Map} map Map.
 * @param {ol.pointer.PointerEvent} pointerEvent Pointer event.
 * @param {boolean=} opt_dragging Is the map currently being dragged?
 * @param {?olx.FrameState=} opt_frameState Frame state.
 */
ol.MapBrowserPointerEvent = function(type, map, pointerEvent, opt_dragging,
    opt_frameState) {
 
  ol.MapBrowserEvent.call(this, type, map, pointerEvent.originalEvent, opt_dragging,
      opt_frameState);
 
  /**
   * @const
   * @type {ol.pointer.PointerEvent}
   */
  this.pointerEvent = pointerEvent;
 
};
ol.inherits(ol.MapBrowserPointerEvent, ol.MapBrowserEvent);
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapevent.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapevent.js

Statements: 12.5% (1 / 8)      Branches: 0% (0 / 2)      Functions: 0% (0 / 1)      Lines: 12.5% (1 / 8)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 402                                                                              
goog.provide('ol.MapEvent');
 
goog.require('ol');
goog.require('ol.events.Event');
 
 
/**
 * @classdesc
 * Events emitted as map events are instances of this type.
 * See {@link ol.Map} for which events trigger a map event.
 *
 * @constructor
 * @extends {ol.events.Event}
 * @implements {oli.MapEvent}
 * @param {string} type Event type.
 * @param {ol.Map} map Map.
 * @param {?olx.FrameState=} opt_frameState Frame state.
 */
ol.MapEvent = function(type, map, opt_frameState) {
 
  ol.events.Event.call(this, type);
 
  /**
   * The map where the event occurred.
   * @type {ol.Map}
   * @api
   */
  this.map = map;
 
  /**
   * The frame state at the time of the event.
   * @type {?olx.FrameState}
   * @api
   */
  this.frameState = opt_frameState !== undefined ? opt_frameState : null;
 
};
ol.inherits(ol.MapEvent, ol.events.Event);
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapeventtype.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapeventtype.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 242                                              
goog.provide('ol.MapEventType');
 
/**
 * @enum {string}
 */
ol.MapEventType = {
 
  /**
   * Triggered after a map frame is rendered.
   * @event ol.MapEvent#postrender
   * @api
   */
  POSTRENDER: 'postrender',
 
  /**
   * Triggered after the map is moved.
   * @event ol.MapEvent#moveend
   * @api
   */
  MOVEEND: 'moveend'
 
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapproperty.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/mapproperty.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 132                        
goog.provide('ol.MapProperty');
 
/**
 * @enum {string}
 */
ol.MapProperty = {
  LAYERGROUP: 'layergroup',
  SIZE: 'size',
  TARGET: 'target',
  VIEW: 'view'
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/math.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/math.js

Statements: 1.49% (1 / 67)      Branches: 0% (0 / 18)      Functions: 0% (0 / 11)      Lines: 1.49% (1 / 67)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 2002                                                                                                                                                                                                                                                                                                                                                                                                              
goog.provide('ol.math');
 
goog.require('ol.asserts');
 
 
/**
 * Takes a number and clamps it to within the provided bounds.
 * @param {number} value The input number.
 * @param {number} min The minimum value to return.
 * @param {number} max The maximum value to return.
 * @return {number} The input number if it is within bounds, or the nearest
 *     number within the bounds.
 */
ol.math.clamp = function(value, min, max) {
  return Math.min(Math.max(value, min), max);
};
 
 
/**
 * Return the hyperbolic cosine of a given number. The method will use the
 * native `Math.cosh` function if it is available, otherwise the hyperbolic
 * cosine will be calculated via the reference implementation of the Mozilla
 * developer network.
 *
 * @param {number} x X.
 * @return {number} Hyperbolic cosine of x.
 */
ol.math.cosh = (function() {
  // Wrapped in a iife, to save the overhead of checking for the native
  // implementation on every invocation.
  var cosh;
  if ('cosh' in Math) {
    // The environment supports the native Math.cosh function, use it…
    cosh = Math.cosh;
  } else {
    // … else, use the reference implementation of MDN:
    cosh = function(x) {
      var y = Math.exp(x);
      return (y + 1 / y) / 2;
    };
  }
  return cosh;
}());
 
 
/**
 * @param {number} x X.
 * @return {number} The smallest power of two greater than or equal to x.
 */
ol.math.roundUpToPowerOfTwo = function(x) {
  ol.asserts.assert(0 < x, 29); // `x` must be greater than `0`
  return Math.pow(2, Math.ceil(Math.log(x) / Math.LN2));
};
 
 
/**
 * Returns the square of the closest distance between the point (x, y) and the
 * line segment (x1, y1) to (x2, y2).
 * @param {number} x X.
 * @param {number} y Y.
 * @param {number} x1 X1.
 * @param {number} y1 Y1.
 * @param {number} x2 X2.
 * @param {number} y2 Y2.
 * @return {number} Squared distance.
 */
ol.math.squaredSegmentDistance = function(x, y, x1, y1, x2, y2) {
  var dx = x2 - x1;
  var dy = y2 - y1;
  if (dx !== 0 || dy !== 0) {
    var t = ((x - x1) * dx + (y - y1) * dy) / (dx * dx + dy * dy);
    if (t > 1) {
      x1 = x2;
      y1 = y2;
    } else if (t > 0) {
      x1 += dx * t;
      y1 += dy * t;
    }
  }
  return ol.math.squaredDistance(x, y, x1, y1);
};
 
 
/**
 * Returns the square of the distance between the points (x1, y1) and (x2, y2).
 * @param {number} x1 X1.
 * @param {number} y1 Y1.
 * @param {number} x2 X2.
 * @param {number} y2 Y2.
 * @return {number} Squared distance.
 */
ol.math.squaredDistance = function(x1, y1, x2, y2) {
  var dx = x2 - x1;
  var dy = y2 - y1;
  return dx * dx + dy * dy;
};
 
 
/**
 * Solves system of linear equations using Gaussian elimination method.
 *
 * @param {Array.<Array.<number>>} mat Augmented matrix (n x n + 1 column)
 *                                     in row-major order.
 * @return {Array.<number>} The resulting vector.
 */
ol.math.solveLinearSystem = function(mat) {
  var n = mat.length;
 
  for (var i = 0; i < n; i++) {
    // Find max in the i-th column (ignoring i - 1 first rows)
    var maxRow = i;
    var maxEl = Math.abs(mat[i][i]);
    for (var r = i + 1; r < n; r++) {
      var absValue = Math.abs(mat[r][i]);
      if (absValue > maxEl) {
        maxEl = absValue;
        maxRow = r;
      }
    }
 
    if (maxEl === 0) {
      return null; // matrix is singular
    }
 
    // Swap max row with i-th (current) row
    var tmp = mat[maxRow];
    mat[maxRow] = mat[i];
    mat[i] = tmp;
 
    // Subtract the i-th row to make all the remaining rows 0 in the i-th column
    for (var j = i + 1; j < n; j++) {
      var coef = -mat[j][i] / mat[i][i];
      for (var k = i; k < n + 1; k++) {
        if (i == k) {
          mat[j][k] = 0;
        } else {
          mat[j][k] += coef * mat[i][k];
        }
      }
    }
  }
 
  // Solve Ax=b for upper triangular matrix A (mat)
  var x = new Array(n);
  for (var l = n - 1; l >= 0; l--) {
    x[l] = mat[l][n] / mat[l][l];
    for (var m = l - 1; m >= 0; m--) {
      mat[m][n] -= mat[m][l] * x[l];
    }
  }
  return x;
};
 
 
/**
 * Converts radians to to degrees.
 *
 * @param {number} angleInRadians Angle in radians.
 * @return {number} Angle in degrees.
 */
ol.math.toDegrees = function(angleInRadians) {
  return angleInRadians * 180 / Math.PI;
};
 
 
/**
 * Converts degrees to radians.
 *
 * @param {number} angleInDegrees Angle in degrees.
 * @return {number} Angle in radians.
 */
ol.math.toRadians = function(angleInDegrees) {
  return angleInDegrees * Math.PI / 180;
};
 
/**
 * Returns the modulo of a / b, depending on the sign of b.
 *
 * @param {number} a Dividend.
 * @param {number} b Divisor.
 * @return {number} Modulo.
 */
ol.math.modulo = function(a, b) {
  var r = a % b;
  return r * b < 0 ? r + b : r;
};
 
/**
 * Calculates the linearly interpolated value of x between a and b.
 *
 * @param {number} a Number
 * @param {number} b Number
 * @param {number} x Value to be interpolated.
 * @return {number} Interpolated value.
 */
ol.math.lerp = function(a, b, x) {
  return a + x * (b - a);
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/net.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/net.js

Statements: 10.53% (2 / 19)      Branches: 0% (0 / 6)      Functions: 0% (0 / 4)      Lines: 10.53% (2 / 19)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 412                                     1                                          
goog.provide('ol.net');
 
goog.require('ol');
 
 
/**
 * Simple JSONP helper. Supports error callbacks and a custom callback param.
 * The error callback will be called when no JSONP is executed after 10 seconds.
 *
 * @param {string} url Request url. A 'callback' query parameter will be
 *     appended.
 * @param {Function} callback Callback on success.
 * @param {function()=} opt_errback Callback on error.
 * @param {string=} opt_callbackParam Custom query parameter for the JSONP
 *     callback. Default is 'callback'.
 */
ol.net.jsonp = function(url, callback, opt_errback, opt_callbackParam) {
  var script = document.createElement('script');
  var key = 'olc_' + ol.getUid(callback);
  function cleanup() {
    delete window[key];
    script.parentNode.removeChild(script);
  }
  script.async = true;
  script.src = url + (url.indexOf('?') == -1 ? '?' : '&') +
      (opt_callbackParam || 'callback') + '=' + key;
  var timer = setTimeout(function() {
    cleanup();
    if (opt_errback) {
      opt_errback();
    }
  }, 10000);
  window[key] = function(data) {
    clearTimeout(timer);
    cleanup();
    callback(data);
  };
  document.getElementsByTagName('head')[0].appendChild(script);
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/obj.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/obj.js

Statements: 4% (1 / 25)      Branches: 0% (0 / 12)      Functions: 0% (0 / 4)      Lines: 4% (1 / 25)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 722                                                                                                                                              
goog.provide('ol.obj');
 
 
/**
 * Polyfill for Object.assign().  Assigns enumerable and own properties from
 * one or more source objects to a target object.
 *
 * @see https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Object/assign
 * @param {!Object} target The target object.
 * @param {...Object} var_sources The source object(s).
 * @return {!Object} The modified target object.
 */
ol.obj.assign = (typeof Object.assign === 'function') ? Object.assign : function(target, var_sources) {
  if (target === undefined || target === null) {
    throw new TypeError('Cannot convert undefined or null to object');
  }
 
  var output = Object(target);
  for (var i = 1, ii = arguments.length; i < ii; ++i) {
    var source = arguments[i];
    if (source !== undefined && source !== null) {
      for (var key in source) {
        if (source.hasOwnProperty(key)) {
          output[key] = source[key];
        }
      }
    }
  }
  return output;
};
 
 
/**
 * Removes all properties from an object.
 * @param {Object} object The object to clear.
 */
ol.obj.clear = function(object) {
  for (var property in object) {
    delete object[property];
  }
};
 
 
/**
 * Get an array of property values from an object.
 * @param {Object<K,V>} object The object from which to get the values.
 * @return {!Array<V>} The property values.
 * @template K,V
 */
ol.obj.getValues = function(object) {
  var values = [];
  for (var property in object) {
    values.push(object[property]);
  }
  return values;
};
 
 
/**
 * Determine if an object has any properties.
 * @param {Object} object The object to check.
 * @return {boolean} The object is empty.
 */
ol.obj.isEmpty = function(object) {
  var property;
  for (property in object) {
    return false;
  }
  return !property;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/object.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/object.js

Statements: 1.89% (1 / 53)      Branches: 0% (0 / 14)      Functions: 0% (0 / 10)      Lines: 1.89% (1 / 53)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 2272                                                                                                                                                                                                                                                                                                                                                                                                                                                                    
goog.provide('ol.Object');
 
goog.require('ol');
goog.require('ol.ObjectEventType');
goog.require('ol.Observable');
goog.require('ol.events.Event');
goog.require('ol.obj');
 
 
/**
 * @classdesc
 * Abstract base class; normally only used for creating subclasses and not
 * instantiated in apps.
 * Most non-trivial classes inherit from this.
 *
 * This extends {@link ol.Observable} with observable properties, where each
 * property is observable as well as the object as a whole.
 *
 * Classes that inherit from this have pre-defined properties, to which you can
 * add your owns. The pre-defined properties are listed in this documentation as
 * 'Observable Properties', and have their own accessors; for example,
 * {@link ol.Map} has a `target` property, accessed with `getTarget()`  and
 * changed with `setTarget()`. Not all properties are however settable. There
 * are also general-purpose accessors `get()` and `set()`. For example,
 * `get('target')` is equivalent to `getTarget()`.
 *
 * The `set` accessors trigger a change event, and you can monitor this by
 * registering a listener. For example, {@link ol.View} has a `center`
 * property, so `view.on('change:center', function(evt) {...});` would call the
 * function whenever the value of the center property changes. Within the
 * function, `evt.target` would be the view, so `evt.target.getCenter()` would
 * return the new center.
 *
 * You can add your own observable properties with
 * `object.set('prop', 'value')`, and retrieve that with `object.get('prop')`.
 * You can listen for changes on that property value with
 * `object.on('change:prop', listener)`. You can get a list of all
 * properties with {@link ol.Object#getProperties object.getProperties()}.
 *
 * Note that the observable properties are separate from standard JS properties.
 * You can, for example, give your map object a title with
 * `map.title='New title'` and with `map.set('title', 'Another title')`. The
 * first will be a `hasOwnProperty`; the second will appear in
 * `getProperties()`. Only the second is observable.
 *
 * Properties can be deleted by using the unset method. E.g.
 * object.unset('foo').
 *
 * @constructor
 * @extends {ol.Observable}
 * @param {Object.<string, *>=} opt_values An object with key-value pairs.
 * @fires ol.Object.Event
 * @api
 */
ol.Object = function(opt_values) {
  ol.Observable.call(this);
 
  // Call ol.getUid to ensure that the order of objects' ids is the same as
  // the order in which they were created.  This also helps to ensure that
  // object properties are always added in the same order, which helps many
  // JavaScript engines generate faster code.
  ol.getUid(this);
 
  /**
   * @private
   * @type {!Object.<string, *>}
   */
  this.values_ = {};
 
  if (opt_values !== undefined) {
    this.setProperties(opt_values);
  }
};
ol.inherits(ol.Object, ol.Observable);
 
 
/**
 * @private
 * @type {Object.<string, string>}
 */
ol.Object.changeEventTypeCache_ = {};
 
 
/**
 * @param {string} key Key name.
 * @return {string} Change name.
 */
ol.Object.getChangeEventType = function(key) {
  return ol.Object.changeEventTypeCache_.hasOwnProperty(key) ?
      ol.Object.changeEventTypeCache_[key] :
      (ol.Object.changeEventTypeCache_[key] = 'change:' + key);
};
 
 
/**
 * Gets a value.
 * @param {string} key Key name.
 * @return {*} Value.
 * @api
 */
ol.Object.prototype.get = function(key) {
  var value;
  if (this.values_.hasOwnProperty(key)) {
    value = this.values_[key];
  }
  return value;
};
 
 
/**
 * Get a list of object property names.
 * @return {Array.<string>} List of property names.
 * @api
 */
ol.Object.prototype.getKeys = function() {
  return Object.keys(this.values_);
};
 
 
/**
 * Get an object of all property names and values.
 * @return {Object.<string, *>} Object.
 * @api
 */
ol.Object.prototype.getProperties = function() {
  return ol.obj.assign({}, this.values_);
};
 
 
/**
 * @param {string} key Key name.
 * @param {*} oldValue Old value.
 */
ol.Object.prototype.notify = function(key, oldValue) {
  var eventType;
  eventType = ol.Object.getChangeEventType(key);
  this.dispatchEvent(new ol.Object.Event(eventType, key, oldValue));
  eventType = ol.ObjectEventType.PROPERTYCHANGE;
  this.dispatchEvent(new ol.Object.Event(eventType, key, oldValue));
};
 
 
/**
 * Sets a value.
 * @param {string} key Key name.
 * @param {*} value Value.
 * @param {boolean=} opt_silent Update without triggering an event.
 * @api
 */
ol.Object.prototype.set = function(key, value, opt_silent) {
  if (opt_silent) {
    this.values_[key] = value;
  } else {
    var oldValue = this.values_[key];
    this.values_[key] = value;
    if (oldValue !== value) {
      this.notify(key, oldValue);
    }
  }
};
 
 
/**
 * Sets a collection of key-value pairs.  Note that this changes any existing
 * properties and adds new ones (it does not remove any existing properties).
 * @param {Object.<string, *>} values Values.
 * @param {boolean=} opt_silent Update without triggering an event.
 * @api
 */
ol.Object.prototype.setProperties = function(values, opt_silent) {
  var key;
  for (key in values) {
    this.set(key, values[key], opt_silent);
  }
};
 
 
/**
 * Unsets a property.
 * @param {string} key Key name.
 * @param {boolean=} opt_silent Unset without triggering an event.
 * @api
 */
ol.Object.prototype.unset = function(key, opt_silent) {
  if (key in this.values_) {
    var oldValue = this.values_[key];
    delete this.values_[key];
    if (!opt_silent) {
      this.notify(key, oldValue);
    }
  }
};
 
 
/**
 * @classdesc
 * Events emitted by {@link ol.Object} instances are instances of this type.
 *
 * @param {string} type The event type.
 * @param {string} key The property name.
 * @param {*} oldValue The old value for `key`.
 * @extends {ol.events.Event}
 * @implements {oli.Object.Event}
 * @constructor
 */
ol.Object.Event = function(type, key, oldValue) {
  ol.events.Event.call(this, type);
 
  /**
   * The name of the property whose value is changing.
   * @type {string}
   * @api
   */
  this.key = key;
 
  /**
   * The old value. To get the new value use `e.target.get(e.key)` where
   * `e` is the event object.
   * @type {*}
   * @api
   */
  this.oldValue = oldValue;
 
};
ol.inherits(ol.Object.Event, ol.events.Event);
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/objecteventtype.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/objecteventtype.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 152                            
goog.provide('ol.ObjectEventType');
 
/**
 * @enum {string}
 */
ol.ObjectEventType = {
  /**
   * Triggered when a property is changed.
   * @event ol.Object.Event#propertychange
   * @api
   */
  PROPERTYCHANGE: 'propertychange'
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/observable.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/observable.js

Statements: 2.38% (1 / 42)      Branches: 0% (0 / 8)      Functions: 0% (0 / 7)      Lines: 2.38% (1 / 42)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 1582                                                                                                                                                                                                                                                                                                                          
goog.provide('ol.Observable');
 
goog.require('ol');
goog.require('ol.events');
goog.require('ol.events.EventTarget');
goog.require('ol.events.EventType');
 
 
/**
 * @classdesc
 * Abstract base class; normally only used for creating subclasses and not
 * instantiated in apps.
 * An event target providing convenient methods for listener registration
 * and unregistration. A generic `change` event is always available through
 * {@link ol.Observable#changed}.
 *
 * @constructor
 * @extends {ol.events.EventTarget}
 * @fires ol.events.Event
 * @struct
 * @api
 */
ol.Observable = function() {
 
  ol.events.EventTarget.call(this);
 
  /**
   * @private
   * @type {number}
   */
  this.revision_ = 0;
 
};
ol.inherits(ol.Observable, ol.events.EventTarget);
 
 
/**
 * Removes an event listener using the key returned by `on()` or `once()`.
 * @param {ol.EventsKey|Array.<ol.EventsKey>} key The key returned by `on()`
 *     or `once()` (or an array of keys).
 * @api
 */
ol.Observable.unByKey = function(key) {
  if (Array.isArray(key)) {
    for (var i = 0, ii = key.length; i < ii; ++i) {
      ol.events.unlistenByKey(key[i]);
    }
  } else {
    ol.events.unlistenByKey(/** @type {ol.EventsKey} */ (key));
  }
};
 
 
/**
 * Increases the revision counter and dispatches a 'change' event.
 * @api
 */
ol.Observable.prototype.changed = function() {
  ++this.revision_;
  this.dispatchEvent(ol.events.EventType.CHANGE);
};
 
 
/**
 * Dispatches an event and calls all listeners listening for events
 * of this type. The event parameter can either be a string or an
 * Object with a `type` property.
 *
 * @param {{type: string,
 *     target: (EventTarget|ol.events.EventTarget|undefined)}|ol.events.Event|
 *     string} event Event object.
 * @function
 * @api
 */
ol.Observable.prototype.dispatchEvent;
 
 
/**
 * Get the version number for this object.  Each time the object is modified,
 * its version number will be incremented.
 * @return {number} Revision.
 * @api
 */
ol.Observable.prototype.getRevision = function() {
  return this.revision_;
};
 
 
/**
 * Listen for a certain type of event.
 * @param {string|Array.<string>} type The event type or array of event types.
 * @param {function(?): ?} listener The listener function.
 * @param {Object=} opt_this The object to use as `this` in `listener`.
 * @return {ol.EventsKey|Array.<ol.EventsKey>} Unique key for the listener. If
 *     called with an array of event types as the first argument, the return
 *     will be an array of keys.
 * @api
 */
ol.Observable.prototype.on = function(type, listener, opt_this) {
  if (Array.isArray(type)) {
    var len = type.length;
    var keys = new Array(len);
    for (var i = 0; i < len; ++i) {
      keys[i] = ol.events.listen(this, type[i], listener, opt_this);
    }
    return keys;
  } else {
    return ol.events.listen(
        this, /** @type {string} */ (type), listener, opt_this);
  }
};
 
 
/**
 * Listen once for a certain type of event.
 * @param {string|Array.<string>} type The event type or array of event types.
 * @param {function(?): ?} listener The listener function.
 * @param {Object=} opt_this The object to use as `this` in `listener`.
 * @return {ol.EventsKey|Array.<ol.EventsKey>} Unique key for the listener. If
 *     called with an array of event types as the first argument, the return
 *     will be an array of keys.
 * @api
 */
ol.Observable.prototype.once = function(type, listener, opt_this) {
  if (Array.isArray(type)) {
    var len = type.length;
    var keys = new Array(len);
    for (var i = 0; i < len; ++i) {
      keys[i] = ol.events.listenOnce(this, type[i], listener, opt_this);
    }
    return keys;
  } else {
    return ol.events.listenOnce(
        this, /** @type {string} */ (type), listener, opt_this);
  }
};
 
 
/**
 * Unlisten for a certain type of event.
 * @param {string|Array.<string>} type The event type or array of event types.
 * @param {function(?): ?} listener The listener function.
 * @param {Object=} opt_this The object which was used as `this` by the
 * `listener`.
 * @api
 */
ol.Observable.prototype.un = function(type, listener, opt_this) {
  if (Array.isArray(type)) {
    for (var i = 0, ii = type.length; i < ii; ++i) {
      ol.events.unlisten(this, type[i], listener, opt_this);
    }
    return;
  } else {
    ol.events.unlisten(this, /** @type {string} */ (type), listener, opt_this);
  }
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/overlay.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/overlay.js

Statements: 0.62% (1 / 162)      Branches: 0% (0 / 97)      Functions: 0% (0 / 23)      Lines: 0.62% (1 / 162)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 5342                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          
goog.provide('ol.Overlay');
 
goog.require('ol');
goog.require('ol.MapEventType');
goog.require('ol.Object');
goog.require('ol.OverlayPositioning');
goog.require('ol.dom');
goog.require('ol.events');
goog.require('ol.extent');
 
 
/**
 * @classdesc
 * An element to be displayed over the map and attached to a single map
 * location.  Like {@link ol.control.Control}, Overlays are visible widgets.
 * Unlike Controls, they are not in a fixed position on the screen, but are tied
 * to a geographical coordinate, so panning the map will move an Overlay but not
 * a Control.
 *
 * Example:
 *
 *     var popup = new ol.Overlay({
 *       element: document.getElementById('popup')
 *     });
 *     popup.setPosition(coordinate);
 *     map.addOverlay(popup);
 *
 * @constructor
 * @extends {ol.Object}
 * @param {olx.OverlayOptions} options Overlay options.
 * @api
 */
ol.Overlay = function(options) {
 
  ol.Object.call(this);
 
  /**
   * @private
   * @type {number|string|undefined}
   */
  this.id_ = options.id;
 
  /**
   * @private
   * @type {boolean}
   */
  this.insertFirst_ = options.insertFirst !== undefined ?
      options.insertFirst : true;
 
  /**
   * @private
   * @type {boolean}
   */
  this.stopEvent_ = options.stopEvent !== undefined ? options.stopEvent : true;
 
  /**
   * @private
   * @type {Element}
   */
  this.element_ = document.createElement('DIV');
  this.element_.className = 'ol-overlay-container';
  this.element_.style.position = 'absolute';
 
  /**
   * @protected
   * @type {boolean}
   */
  this.autoPan = options.autoPan !== undefined ? options.autoPan : false;
 
  /**
   * @private
   * @type {olx.OverlayPanOptions}
   */
  this.autoPanAnimation_ = options.autoPanAnimation ||
      /** @type {olx.OverlayPanOptions} */ ({});
 
  /**
   * @private
   * @type {number}
   */
  this.autoPanMargin_ = options.autoPanMargin !== undefined ?
      options.autoPanMargin : 20;
 
  /**
   * @private
   * @type {{bottom_: string,
   *         left_: string,
   *         right_: string,
   *         top_: string,
   *         visible: boolean}}
   */
  this.rendered_ = {
    bottom_: '',
    left_: '',
    right_: '',
    top_: '',
    visible: true
  };
 
  /**
   * @private
   * @type {?ol.EventsKey}
   */
  this.mapPostrenderListenerKey_ = null;
 
  ol.events.listen(
      this, ol.Object.getChangeEventType(ol.Overlay.Property_.ELEMENT),
      this.handleElementChanged, this);
 
  ol.events.listen(
      this, ol.Object.getChangeEventType(ol.Overlay.Property_.MAP),
      this.handleMapChanged, this);
 
  ol.events.listen(
      this, ol.Object.getChangeEventType(ol.Overlay.Property_.OFFSET),
      this.handleOffsetChanged, this);
 
  ol.events.listen(
      this, ol.Object.getChangeEventType(ol.Overlay.Property_.POSITION),
      this.handlePositionChanged, this);
 
  ol.events.listen(
      this, ol.Object.getChangeEventType(ol.Overlay.Property_.POSITIONING),
      this.handlePositioningChanged, this);
 
  if (options.element !== undefined) {
    this.setElement(options.element);
  }
 
  this.setOffset(options.offset !== undefined ? options.offset : [0, 0]);
 
  this.setPositioning(options.positioning !== undefined ?
      /** @type {ol.OverlayPositioning} */ (options.positioning) :
      ol.OverlayPositioning.TOP_LEFT);
 
  if (options.position !== undefined) {
    this.setPosition(options.position);
  }
 
};
ol.inherits(ol.Overlay, ol.Object);
 
 
/**
 * Get the DOM element of this overlay.
 * @return {Element|undefined} The Element containing the overlay.
 * @observable
 * @api
 */
ol.Overlay.prototype.getElement = function() {
  return /** @type {Element|undefined} */ (
      this.get(ol.Overlay.Property_.ELEMENT));
};
 
 
/**
 * Get the overlay identifier which is set on constructor.
 * @return {number|string|undefined} Id.
 * @api
 */
ol.Overlay.prototype.getId = function() {
  return this.id_;
};
 
 
/**
 * Get the map associated with this overlay.
 * @return {ol.Map|undefined} The map that the overlay is part of.
 * @observable
 * @api
 */
ol.Overlay.prototype.getMap = function() {
  return /** @type {ol.Map|undefined} */ (
      this.get(ol.Overlay.Property_.MAP));
};
 
 
/**
 * Get the offset of this overlay.
 * @return {Array.<number>} The offset.
 * @observable
 * @api
 */
ol.Overlay.prototype.getOffset = function() {
  return /** @type {Array.<number>} */ (
      this.get(ol.Overlay.Property_.OFFSET));
};
 
 
/**
 * Get the current position of this overlay.
 * @return {ol.Coordinate|undefined} The spatial point that the overlay is
 *     anchored at.
 * @observable
 * @api
 */
ol.Overlay.prototype.getPosition = function() {
  return /** @type {ol.Coordinate|undefined} */ (
      this.get(ol.Overlay.Property_.POSITION));
};
 
 
/**
 * Get the current positioning of this overlay.
 * @return {ol.OverlayPositioning} How the overlay is positioned
 *     relative to its point on the map.
 * @observable
 * @api
 */
ol.Overlay.prototype.getPositioning = function() {
  return /** @type {ol.OverlayPositioning} */ (
      this.get(ol.Overlay.Property_.POSITIONING));
};
 
 
/**
 * @protected
 */
ol.Overlay.prototype.handleElementChanged = function() {
  ol.dom.removeChildren(this.element_);
  var element = this.getElement();
  if (element) {
    this.element_.appendChild(element);
  }
};
 
 
/**
 * @protected
 */
ol.Overlay.prototype.handleMapChanged = function() {
  if (this.mapPostrenderListenerKey_) {
    ol.dom.removeNode(this.element_);
    ol.events.unlistenByKey(this.mapPostrenderListenerKey_);
    this.mapPostrenderListenerKey_ = null;
  }
  var map = this.getMap();
  if (map) {
    this.mapPostrenderListenerKey_ = ol.events.listen(map,
        ol.MapEventType.POSTRENDER, this.render, this);
    this.updatePixelPosition();
    var container = this.stopEvent_ ?
        map.getOverlayContainerStopEvent() : map.getOverlayContainer();
    if (this.insertFirst_) {
      container.insertBefore(this.element_, container.childNodes[0] || null);
    } else {
      container.appendChild(this.element_);
    }
  }
};
 
 
/**
 * @protected
 */
ol.Overlay.prototype.render = function() {
  this.updatePixelPosition();
};
 
 
/**
 * @protected
 */
ol.Overlay.prototype.handleOffsetChanged = function() {
  this.updatePixelPosition();
};
 
 
/**
 * @protected
 */
ol.Overlay.prototype.handlePositionChanged = function() {
  this.updatePixelPosition();
  if (this.get(ol.Overlay.Property_.POSITION) && this.autoPan) {
    this.panIntoView_();
  }
};
 
 
/**
 * @protected
 */
ol.Overlay.prototype.handlePositioningChanged = function() {
  this.updatePixelPosition();
};
 
 
/**
 * Set the DOM element to be associated with this overlay.
 * @param {Element|undefined} element The Element containing the overlay.
 * @observable
 * @api
 */
ol.Overlay.prototype.setElement = function(element) {
  this.set(ol.Overlay.Property_.ELEMENT, element);
};
 
 
/**
 * Set the map to be associated with this overlay.
 * @param {ol.Map|undefined} map The map that the overlay is part of.
 * @observable
 * @api
 */
ol.Overlay.prototype.setMap = function(map) {
  this.set(ol.Overlay.Property_.MAP, map);
};
 
 
/**
 * Set the offset for this overlay.
 * @param {Array.<number>} offset Offset.
 * @observable
 * @api
 */
ol.Overlay.prototype.setOffset = function(offset) {
  this.set(ol.Overlay.Property_.OFFSET, offset);
};
 
 
/**
 * Set the position for this overlay. If the position is `undefined` the
 * overlay is hidden.
 * @param {ol.Coordinate|undefined} position The spatial point that the overlay
 *     is anchored at.
 * @observable
 * @api
 */
ol.Overlay.prototype.setPosition = function(position) {
  this.set(ol.Overlay.Property_.POSITION, position);
};
 
 
/**
 * Pan the map so that the overlay is entirely visible in the current viewport
 * (if necessary).
 * @private
 */
ol.Overlay.prototype.panIntoView_ = function() {
  var map = this.getMap();
 
  if (!map || !map.getTargetElement()) {
    return;
  }
 
  var mapRect = this.getRect_(map.getTargetElement(), map.getSize());
  var element = /** @type {!Element} */ (this.getElement());
  var overlayRect = this.getRect_(element,
      [ol.dom.outerWidth(element), ol.dom.outerHeight(element)]);
 
  var margin = this.autoPanMargin_;
  if (!ol.extent.containsExtent(mapRect, overlayRect)) {
    // the overlay is not completely inside the viewport, so pan the map
    var offsetLeft = overlayRect[0] - mapRect[0];
    var offsetRight = mapRect[2] - overlayRect[2];
    var offsetTop = overlayRect[1] - mapRect[1];
    var offsetBottom = mapRect[3] - overlayRect[3];
 
    var delta = [0, 0];
    if (offsetLeft < 0) {
      // move map to the left
      delta[0] = offsetLeft - margin;
    } else if (offsetRight < 0) {
      // move map to the right
      delta[0] = Math.abs(offsetRight) + margin;
    }
    if (offsetTop < 0) {
      // move map up
      delta[1] = offsetTop - margin;
    } else if (offsetBottom < 0) {
      // move map down
      delta[1] = Math.abs(offsetBottom) + margin;
    }
 
    if (delta[0] !== 0 || delta[1] !== 0) {
      var center = /** @type {ol.Coordinate} */ (map.getView().getCenter());
      var centerPx = map.getPixelFromCoordinate(center);
      var newCenterPx = [
        centerPx[0] + delta[0],
        centerPx[1] + delta[1]
      ];
 
      map.getView().animate({
        center: map.getCoordinateFromPixel(newCenterPx),
        duration: this.autoPanAnimation_.duration,
        easing: this.autoPanAnimation_.easing
      });
    }
  }
};
 
 
/**
 * Get the extent of an element relative to the document
 * @param {Element|undefined} element The element.
 * @param {ol.Size|undefined} size The size of the element.
 * @return {ol.Extent} The extent.
 * @private
 */
ol.Overlay.prototype.getRect_ = function(element, size) {
  var box = element.getBoundingClientRect();
  var offsetX = box.left + window.pageXOffset;
  var offsetY = box.top + window.pageYOffset;
  return [
    offsetX,
    offsetY,
    offsetX + size[0],
    offsetY + size[1]
  ];
};
 
 
/**
 * Set the positioning for this overlay.
 * @param {ol.OverlayPositioning} positioning how the overlay is
 *     positioned relative to its point on the map.
 * @observable
 * @api
 */
ol.Overlay.prototype.setPositioning = function(positioning) {
  this.set(ol.Overlay.Property_.POSITIONING, positioning);
};
 
 
/**
 * Modify the visibility of the element.
 * @param {boolean} visible Element visibility.
 * @protected
 */
ol.Overlay.prototype.setVisible = function(visible) {
  if (this.rendered_.visible !== visible) {
    this.element_.style.display = visible ? '' : 'none';
    this.rendered_.visible = visible;
  }
};
 
 
/**
 * Update pixel position.
 * @protected
 */
ol.Overlay.prototype.updatePixelPosition = function() {
  var map = this.getMap();
  var position = this.getPosition();
  if (!map || !map.isRendered() || !position) {
    this.setVisible(false);
    return;
  }
 
  var pixel = map.getPixelFromCoordinate(position);
  var mapSize = map.getSize();
  this.updateRenderedPosition(pixel, mapSize);
};
 
 
/**
 * @param {ol.Pixel} pixel The pixel location.
 * @param {ol.Size|undefined} mapSize The map size.
 * @protected
 */
ol.Overlay.prototype.updateRenderedPosition = function(pixel, mapSize) {
  var style = this.element_.style;
  var offset = this.getOffset();
 
  var positioning = this.getPositioning();
 
  this.setVisible(true);
 
  var offsetX = offset[0];
  var offsetY = offset[1];
  if (positioning == ol.OverlayPositioning.BOTTOM_RIGHT ||
      positioning == ol.OverlayPositioning.CENTER_RIGHT ||
      positioning == ol.OverlayPositioning.TOP_RIGHT) {
    if (this.rendered_.left_ !== '') {
      this.rendered_.left_ = style.left = '';
    }
    var right = Math.round(mapSize[0] - pixel[0] - offsetX) + 'px';
    if (this.rendered_.right_ != right) {
      this.rendered_.right_ = style.right = right;
    }
  } else {
    if (this.rendered_.right_ !== '') {
      this.rendered_.right_ = style.right = '';
    }
    if (positioning == ol.OverlayPositioning.BOTTOM_CENTER ||
        positioning == ol.OverlayPositioning.CENTER_CENTER ||
        positioning == ol.OverlayPositioning.TOP_CENTER) {
      offsetX -= this.element_.offsetWidth / 2;
    }
    var left = Math.round(pixel[0] + offsetX) + 'px';
    if (this.rendered_.left_ != left) {
      this.rendered_.left_ = style.left = left;
    }
  }
  if (positioning == ol.OverlayPositioning.BOTTOM_LEFT ||
      positioning == ol.OverlayPositioning.BOTTOM_CENTER ||
      positioning == ol.OverlayPositioning.BOTTOM_RIGHT) {
    if (this.rendered_.top_ !== '') {
      this.rendered_.top_ = style.top = '';
    }
    var bottom = Math.round(mapSize[1] - pixel[1] - offsetY) + 'px';
    if (this.rendered_.bottom_ != bottom) {
      this.rendered_.bottom_ = style.bottom = bottom;
    }
  } else {
    if (this.rendered_.bottom_ !== '') {
      this.rendered_.bottom_ = style.bottom = '';
    }
    if (positioning == ol.OverlayPositioning.CENTER_LEFT ||
        positioning == ol.OverlayPositioning.CENTER_CENTER ||
        positioning == ol.OverlayPositioning.CENTER_RIGHT) {
      offsetY -= this.element_.offsetHeight / 2;
    }
    var top = Math.round(pixel[1] + offsetY) + 'px';
    if (this.rendered_.top_ != top) {
      this.rendered_.top_ = style.top = top;
    }
  }
};
 
 
/**
 * @enum {string}
 * @private
 */
ol.Overlay.Property_ = {
  ELEMENT: 'element',
  MAP: 'map',
  OFFSET: 'offset',
  POSITION: 'position',
  POSITIONING: 'positioning'
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/overlaypositioning.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/overlaypositioning.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 212                                        
goog.provide('ol.OverlayPositioning');
 
/**
 * Overlay position: `'bottom-left'`, `'bottom-center'`,  `'bottom-right'`,
 * `'center-left'`, `'center-center'`, `'center-right'`, `'top-left'`,
 * `'top-center'`, `'top-right'`
 * @enum {string}
 */
ol.OverlayPositioning = {
  BOTTOM_LEFT: 'bottom-left',
  BOTTOM_CENTER: 'bottom-center',
  BOTTOM_RIGHT: 'bottom-right',
  CENTER_LEFT: 'center-left',
  CENTER_CENTER: 'center-center',
  CENTER_RIGHT: 'center-right',
  TOP_LEFT: 'top-left',
  TOP_CENTER: 'top-center',
  TOP_RIGHT: 'top-right'
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/proj.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/proj.js

Statements: 0.65% (1 / 153)      Branches: 0% (0 / 59)      Functions: 0% (0 / 28)      Lines: 0.65% (1 / 153)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 4942                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          
goog.provide('ol.proj');
 
goog.require('ol');
goog.require('ol.extent');
goog.require('ol.proj.EPSG3857');
goog.require('ol.proj.EPSG4326');
goog.require('ol.proj.Projection');
goog.require('ol.proj.Units');
goog.require('ol.proj.proj4');
goog.require('ol.proj.projections');
goog.require('ol.proj.transforms');
goog.require('ol.sphere.NORMAL');
 
 
/**
 * Meters per unit lookup table.
 * @const
 * @type {Object.<ol.proj.Units, number>}
 * @api
 */
ol.proj.METERS_PER_UNIT = ol.proj.Units.METERS_PER_UNIT;
 
 
if (ol.ENABLE_PROJ4JS) {
  /**
   * Register proj4. If not explicitly registered, it will be assumed that
   * proj4js will be loaded in the global namespace. For example in a
   * browserify ES6 environment you could use:
   *
   *     import ol from 'openlayers';
   *     import proj4 from 'proj4';
   *     ol.proj.setProj4(proj4);
   *
   * @param {Proj4} proj4 Proj4.
   * @api
   */
  ol.proj.setProj4 = function(proj4) {
    ol.proj.proj4.set(proj4);
  };
}
 
 
/**
 * Get the resolution of the point in degrees or distance units.
 * For projections with degrees as the unit this will simply return the
 * provided resolution. For other projections the point resolution is
 * estimated by transforming the 'point' pixel to EPSG:4326,
 * measuring its width and height on the normal sphere,
 * and taking the average of the width and height.
 * @param {ol.proj.Projection} projection The projection.
 * @param {number} resolution Nominal resolution in projection units.
 * @param {ol.Coordinate} point Point to find adjusted resolution at.
 * @return {number} Point resolution at point in projection units.
 * @api
 */
ol.proj.getPointResolution = function(projection, resolution, point) {
  var pointResolution;
  var getter = projection.getPointResolutionFunc();
  if (getter) {
    pointResolution = getter(resolution, point);
  } else {
    var units = projection.getUnits();
    if (units == ol.proj.Units.DEGREES) {
      pointResolution = resolution;
    } else {
      // Estimate point resolution by transforming the center pixel to EPSG:4326,
      // measuring its width and height on the normal sphere, and taking the
      // average of the width and height.
      var toEPSG4326 = ol.proj.getTransformFromProjections(projection, ol.proj.get('EPSG:4326'));
      var vertices = [
        point[0] - resolution / 2, point[1],
        point[0] + resolution / 2, point[1],
        point[0], point[1] - resolution / 2,
        point[0], point[1] + resolution / 2
      ];
      vertices = toEPSG4326(vertices, vertices, 2);
      var width = ol.sphere.NORMAL.haversineDistance(
          vertices.slice(0, 2), vertices.slice(2, 4));
      var height = ol.sphere.NORMAL.haversineDistance(
          vertices.slice(4, 6), vertices.slice(6, 8));
      pointResolution = (width + height) / 2;
      var metersPerUnit = projection.getMetersPerUnit();
      if (metersPerUnit !== undefined) {
        pointResolution /= metersPerUnit;
      }
    }
  }
  return pointResolution;
};
 
 
/**
 * Registers transformation functions that don't alter coordinates. Those allow
 * to transform between projections with equal meaning.
 *
 * @param {Array.<ol.proj.Projection>} projections Projections.
 * @api
 */
ol.proj.addEquivalentProjections = function(projections) {
  ol.proj.addProjections(projections);
  projections.forEach(function(source) {
    projections.forEach(function(destination) {
      if (source !== destination) {
        ol.proj.transforms.add(source, destination, ol.proj.cloneTransform);
      }
    });
  });
};
 
 
/**
 * Registers transformation functions to convert coordinates in any projection
 * in projection1 to any projection in projection2.
 *
 * @param {Array.<ol.proj.Projection>} projections1 Projections with equal
 *     meaning.
 * @param {Array.<ol.proj.Projection>} projections2 Projections with equal
 *     meaning.
 * @param {ol.TransformFunction} forwardTransform Transformation from any
 *   projection in projection1 to any projection in projection2.
 * @param {ol.TransformFunction} inverseTransform Transform from any projection
 *   in projection2 to any projection in projection1..
 */
ol.proj.addEquivalentTransforms = function(projections1, projections2, forwardTransform, inverseTransform) {
  projections1.forEach(function(projection1) {
    projections2.forEach(function(projection2) {
      ol.proj.transforms.add(projection1, projection2, forwardTransform);
      ol.proj.transforms.add(projection2, projection1, inverseTransform);
    });
  });
};
 
 
/**
 * Add a Projection object to the list of supported projections that can be
 * looked up by their code.
 *
 * @param {ol.proj.Projection} projection Projection instance.
 * @api
 */
ol.proj.addProjection = function(projection) {
  ol.proj.projections.add(projection.getCode(), projection);
  ol.proj.transforms.add(projection, projection, ol.proj.cloneTransform);
};
 
 
/**
 * @param {Array.<ol.proj.Projection>} projections Projections.
 */
ol.proj.addProjections = function(projections) {
  var addedProjections = [];
  projections.forEach(function(projection) {
    addedProjections.push(ol.proj.addProjection(projection));
  });
};
 
 
/**
 * Clear all cached projections and transforms.
 */
ol.proj.clearAllProjections = function() {
  ol.proj.projections.clear();
  ol.proj.transforms.clear();
};
 
 
/**
 * @param {ol.proj.Projection|string|undefined} projection Projection.
 * @param {string} defaultCode Default code.
 * @return {ol.proj.Projection} Projection.
 */
ol.proj.createProjection = function(projection, defaultCode) {
  if (!projection) {
    return ol.proj.get(defaultCode);
  } else if (typeof projection === 'string') {
    return ol.proj.get(projection);
  } else {
    return /** @type {ol.proj.Projection} */ (projection);
  }
};
 
 
/**
 * Registers coordinate transform functions to convert coordinates between the
 * source projection and the destination projection.
 * The forward and inverse functions convert coordinate pairs; this function
 * converts these into the functions used internally which also handle
 * extents and coordinate arrays.
 *
 * @param {ol.ProjectionLike} source Source projection.
 * @param {ol.ProjectionLike} destination Destination projection.
 * @param {function(ol.Coordinate): ol.Coordinate} forward The forward transform
 *     function (that is, from the source projection to the destination
 *     projection) that takes a {@link ol.Coordinate} as argument and returns
 *     the transformed {@link ol.Coordinate}.
 * @param {function(ol.Coordinate): ol.Coordinate} inverse The inverse transform
 *     function (that is, from the destination projection to the source
 *     projection) that takes a {@link ol.Coordinate} as argument and returns
 *     the transformed {@link ol.Coordinate}.
 * @api
 */
ol.proj.addCoordinateTransforms = function(source, destination, forward, inverse) {
  var sourceProj = ol.proj.get(source);
  var destProj = ol.proj.get(destination);
  ol.proj.transforms.add(sourceProj, destProj,
      ol.proj.createTransformFromCoordinateTransform(forward));
  ol.proj.transforms.add(destProj, sourceProj,
      ol.proj.createTransformFromCoordinateTransform(inverse));
};
 
 
/**
 * Creates a {@link ol.TransformFunction} from a simple 2D coordinate transform
 * function.
 * @param {function(ol.Coordinate): ol.Coordinate} transform Coordinate
 *     transform.
 * @return {ol.TransformFunction} Transform function.
 */
ol.proj.createTransformFromCoordinateTransform = function(transform) {
  return (
      /**
       * @param {Array.<number>} input Input.
       * @param {Array.<number>=} opt_output Output.
       * @param {number=} opt_dimension Dimension.
       * @return {Array.<number>} Output.
       */
      function(input, opt_output, opt_dimension) {
        var length = input.length;
        var dimension = opt_dimension !== undefined ? opt_dimension : 2;
        var output = opt_output !== undefined ? opt_output : new Array(length);
        var point, i, j;
        for (i = 0; i < length; i += dimension) {
          point = transform([input[i], input[i + 1]]);
          output[i] = point[0];
          output[i + 1] = point[1];
          for (j = dimension - 1; j >= 2; --j) {
            output[i + j] = input[i + j];
          }
        }
        return output;
      });
};
 
 
/**
 * Transforms a coordinate from longitude/latitude to a different projection.
 * @param {ol.Coordinate} coordinate Coordinate as longitude and latitude, i.e.
 *     an array with longitude as 1st and latitude as 2nd element.
 * @param {ol.ProjectionLike=} opt_projection Target projection. The
 *     default is Web Mercator, i.e. 'EPSG:3857'.
 * @return {ol.Coordinate} Coordinate projected to the target projection.
 * @api
 */
ol.proj.fromLonLat = function(coordinate, opt_projection) {
  return ol.proj.transform(coordinate, 'EPSG:4326',
      opt_projection !== undefined ? opt_projection : 'EPSG:3857');
};
 
 
/**
 * Transforms a coordinate to longitude/latitude.
 * @param {ol.Coordinate} coordinate Projected coordinate.
 * @param {ol.ProjectionLike=} opt_projection Projection of the coordinate.
 *     The default is Web Mercator, i.e. 'EPSG:3857'.
 * @return {ol.Coordinate} Coordinate as longitude and latitude, i.e. an array
 *     with longitude as 1st and latitude as 2nd element.
 * @api
 */
ol.proj.toLonLat = function(coordinate, opt_projection) {
  return ol.proj.transform(coordinate,
      opt_projection !== undefined ? opt_projection : 'EPSG:3857', 'EPSG:4326');
};
 
 
/**
 * Fetches a Projection object for the code specified.
 *
 * @param {ol.ProjectionLike} projectionLike Either a code string which is
 *     a combination of authority and identifier such as "EPSG:4326", or an
 *     existing projection object, or undefined.
 * @return {ol.proj.Projection} Projection object, or null if not in list.
 * @api
 */
ol.proj.get = function(projectionLike) {
  var projection = null;
  if (projectionLike instanceof ol.proj.Projection) {
    projection = projectionLike;
  } else if (typeof projectionLike === 'string') {
    var code = projectionLike;
    projection = ol.proj.projections.get(code);
    if (ol.ENABLE_PROJ4JS) {
      var proj4js = ol.proj.proj4.get();
      if (!projection && typeof proj4js == 'function' &&
          proj4js.defs(code) !== undefined) {
        projection = new ol.proj.Projection({code: code});
        ol.proj.addProjection(projection);
      }
    }
  }
  return projection;
};
 
 
/**
 * Checks if two projections are the same, that is every coordinate in one
 * projection does represent the same geographic point as the same coordinate in
 * the other projection.
 *
 * @param {ol.proj.Projection} projection1 Projection 1.
 * @param {ol.proj.Projection} projection2 Projection 2.
 * @return {boolean} Equivalent.
 * @api
 */
ol.proj.equivalent = function(projection1, projection2) {
  if (projection1 === projection2) {
    return true;
  }
  var equalUnits = projection1.getUnits() === projection2.getUnits();
  if (projection1.getCode() === projection2.getCode()) {
    return equalUnits;
  } else {
    var transformFn = ol.proj.getTransformFromProjections(
        projection1, projection2);
    return transformFn === ol.proj.cloneTransform && equalUnits;
  }
};
 
 
/**
 * Given the projection-like objects, searches for a transformation
 * function to convert a coordinates array from the source projection to the
 * destination projection.
 *
 * @param {ol.ProjectionLike} source Source.
 * @param {ol.ProjectionLike} destination Destination.
 * @return {ol.TransformFunction} Transform function.
 * @api
 */
ol.proj.getTransform = function(source, destination) {
  var sourceProjection = ol.proj.get(source);
  var destinationProjection = ol.proj.get(destination);
  return ol.proj.getTransformFromProjections(
      sourceProjection, destinationProjection);
};
 
 
/**
 * Searches in the list of transform functions for the function for converting
 * coordinates from the source projection to the destination projection.
 *
 * @param {ol.proj.Projection} sourceProjection Source Projection object.
 * @param {ol.proj.Projection} destinationProjection Destination Projection
 *     object.
 * @return {ol.TransformFunction} Transform function.
 */
ol.proj.getTransformFromProjections = function(sourceProjection, destinationProjection) {
  var sourceCode = sourceProjection.getCode();
  var destinationCode = destinationProjection.getCode();
  var transform = ol.proj.transforms.get(sourceCode, destinationCode);
  if (ol.ENABLE_PROJ4JS && !transform) {
    var proj4js = ol.proj.proj4.get();
    if (typeof proj4js == 'function') {
      var sourceDef = proj4js.defs(sourceCode);
      var destinationDef = proj4js.defs(destinationCode);
 
      if (sourceDef !== undefined && destinationDef !== undefined) {
        if (sourceDef === destinationDef) {
          ol.proj.addEquivalentProjections([destinationProjection, sourceProjection]);
        } else {
          var proj4Transform = proj4js(destinationCode, sourceCode);
          ol.proj.addCoordinateTransforms(destinationProjection, sourceProjection,
              proj4Transform.forward, proj4Transform.inverse);
        }
        transform = ol.proj.transforms.get(sourceCode, destinationCode);
      }
    }
  }
  if (!transform) {
    transform = ol.proj.identityTransform;
  }
  return transform;
};
 
 
/**
 * @param {Array.<number>} input Input coordinate array.
 * @param {Array.<number>=} opt_output Output array of coordinate values.
 * @param {number=} opt_dimension Dimension.
 * @return {Array.<number>} Input coordinate array (same array as input).
 */
ol.proj.identityTransform = function(input, opt_output, opt_dimension) {
  if (opt_output !== undefined && input !== opt_output) {
    for (var i = 0, ii = input.length; i < ii; ++i) {
      opt_output[i] = input[i];
    }
    input = opt_output;
  }
  return input;
};
 
 
/**
 * @param {Array.<number>} input Input coordinate array.
 * @param {Array.<number>=} opt_output Output array of coordinate values.
 * @param {number=} opt_dimension Dimension.
 * @return {Array.<number>} Output coordinate array (new array, same coordinate
 *     values).
 */
ol.proj.cloneTransform = function(input, opt_output, opt_dimension) {
  var output;
  if (opt_output !== undefined) {
    for (var i = 0, ii = input.length; i < ii; ++i) {
      opt_output[i] = input[i];
    }
    output = opt_output;
  } else {
    output = input.slice();
  }
  return output;
};
 
 
/**
 * Transforms a coordinate from source projection to destination projection.
 * This returns a new coordinate (and does not modify the original).
 *
 * See {@link ol.proj.transformExtent} for extent transformation.
 * See the transform method of {@link ol.geom.Geometry} and its subclasses for
 * geometry transforms.
 *
 * @param {ol.Coordinate} coordinate Coordinate.
 * @param {ol.ProjectionLike} source Source projection-like.
 * @param {ol.ProjectionLike} destination Destination projection-like.
 * @return {ol.Coordinate} Coordinate.
 * @api
 */
ol.proj.transform = function(coordinate, source, destination) {
  var transformFn = ol.proj.getTransform(source, destination);
  return transformFn(coordinate, undefined, coordinate.length);
};
 
 
/**
 * Transforms an extent from source projection to destination projection.  This
 * returns a new extent (and does not modify the original).
 *
 * @param {ol.Extent} extent The extent to transform.
 * @param {ol.ProjectionLike} source Source projection-like.
 * @param {ol.ProjectionLike} destination Destination projection-like.
 * @return {ol.Extent} The transformed extent.
 * @api
 */
ol.proj.transformExtent = function(extent, source, destination) {
  var transformFn = ol.proj.getTransform(source, destination);
  return ol.extent.applyTransform(extent, transformFn);
};
 
 
/**
 * Transforms the given point to the destination projection.
 *
 * @param {ol.Coordinate} point Point.
 * @param {ol.proj.Projection} sourceProjection Source projection.
 * @param {ol.proj.Projection} destinationProjection Destination projection.
 * @return {ol.Coordinate} Point.
 */
ol.proj.transformWithProjections = function(point, sourceProjection, destinationProjection) {
  var transformFn = ol.proj.getTransformFromProjections(
      sourceProjection, destinationProjection);
  return transformFn(point);
};
 
/**
 * Add transforms to and from EPSG:4326 and EPSG:3857.  This function is called
 * by when this module is executed and should only need to be called again after
 * `ol.proj.clearAllProjections()` is called (e.g. in tests).
 */
ol.proj.addCommon = function() {
  // Add transformations that don't alter coordinates to convert within set of
  // projections with equal meaning.
  ol.proj.addEquivalentProjections(ol.proj.EPSG3857.PROJECTIONS);
  ol.proj.addEquivalentProjections(ol.proj.EPSG4326.PROJECTIONS);
  // Add transformations to convert EPSG:4326 like coordinates to EPSG:3857 like
  // coordinates and back.
  ol.proj.addEquivalentTransforms(
      ol.proj.EPSG4326.PROJECTIONS,
      ol.proj.EPSG3857.PROJECTIONS,
      ol.proj.EPSG3857.fromEPSG4326,
      ol.proj.EPSG3857.toEPSG4326);
};
 
ol.proj.addCommon();
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/render.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/render.js

Statements: 5.88% (1 / 17)      Branches: 0% (0 / 6)      Functions: 0% (0 / 1)      Lines: 5.88% (1 / 17)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 452                                                                                        
goog.provide('ol.render');
 
goog.require('ol.has');
goog.require('ol.transform');
goog.require('ol.render.canvas.Immediate');
 
 
/**
 * Binds a Canvas Immediate API to a canvas context, to allow drawing geometries
 * to the context's canvas.
 *
 * The units for geometry coordinates are css pixels relative to the top left
 * corner of the canvas element.
 * ```js
 * var canvas = document.createElement('canvas');
 * var render = ol.render.toContext(canvas.getContext('2d'),
 *     { size: [100, 100] });
 * render.setFillStrokeStyle(new ol.style.Fill({ color: blue }));
 * render.drawPolygon(
 *     new ol.geom.Polygon([[[0, 0], [100, 100], [100, 0], [0, 0]]]));
 * ```
 *
 * @param {CanvasRenderingContext2D} context Canvas context.
 * @param {olx.render.ToContextOptions=} opt_options Options.
 * @return {ol.render.canvas.Immediate} Canvas Immediate.
 * @api
 */
ol.render.toContext = function(context, opt_options) {
  var canvas = context.canvas;
  var options = opt_options ? opt_options : {};
  var pixelRatio = options.pixelRatio || ol.has.DEVICE_PIXEL_RATIO;
  var size = options.size;
  if (size) {
    canvas.width = size[0] * pixelRatio;
    canvas.height = size[1] * pixelRatio;
    canvas.style.width = size[0] + 'px';
    canvas.style.height = size[1] + 'px';
  }
  var extent = [0, 0, canvas.width, canvas.height];
  var transform = ol.transform.scale(ol.transform.create(), pixelRatio, pixelRatio);
  return new ol.render.canvas.Immediate(context, pixelRatio, extent, transform,
      0);
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/reproj.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/reproj.js

Statements: 1.11% (1 / 90)      Branches: 0% (0 / 14)      Functions: 0% (0 / 7)      Lines: 1.11% (1 / 90)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 2402                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              
goog.provide('ol.reproj');
 
goog.require('ol.dom');
goog.require('ol.extent');
goog.require('ol.math');
goog.require('ol.proj');
 
 
/**
 * Calculates ideal resolution to use from the source in order to achieve
 * pixel mapping as close as possible to 1:1 during reprojection.
 * The resolution is calculated regardless of what resolutions
 * are actually available in the dataset (TileGrid, Image, ...).
 *
 * @param {ol.proj.Projection} sourceProj Source projection.
 * @param {ol.proj.Projection} targetProj Target projection.
 * @param {ol.Coordinate} targetCenter Target center.
 * @param {number} targetResolution Target resolution.
 * @return {number} The best resolution to use. Can be +-Infinity, NaN or 0.
 */
ol.reproj.calculateSourceResolution = function(sourceProj, targetProj,
    targetCenter, targetResolution) {
 
  var sourceCenter = ol.proj.transform(targetCenter, targetProj, sourceProj);
 
  // calculate the ideal resolution of the source data
  var sourceResolution =
      ol.proj.getPointResolution(targetProj, targetResolution, targetCenter);
 
  var targetMetersPerUnit = targetProj.getMetersPerUnit();
  if (targetMetersPerUnit !== undefined) {
    sourceResolution *= targetMetersPerUnit;
  }
  var sourceMetersPerUnit = sourceProj.getMetersPerUnit();
  if (sourceMetersPerUnit !== undefined) {
    sourceResolution /= sourceMetersPerUnit;
  }
 
  // Based on the projection properties, the point resolution at the specified
  // coordinates may be slightly different. We need to reverse-compensate this
  // in order to achieve optimal results.
 
  var compensationFactor =
      ol.proj.getPointResolution(sourceProj, sourceResolution, sourceCenter) /
      sourceResolution;
 
  if (isFinite(compensationFactor) && compensationFactor > 0) {
    sourceResolution /= compensationFactor;
  }
 
  return sourceResolution;
};
 
 
/**
 * Enlarge the clipping triangle point by 1 pixel to ensure the edges overlap
 * in order to mask gaps caused by antialiasing.
 *
 * @param {number} centroidX Centroid of the triangle (x coordinate in pixels).
 * @param {number} centroidY Centroid of the triangle (y coordinate in pixels).
 * @param {number} x X coordinate of the point (in pixels).
 * @param {number} y Y coordinate of the point (in pixels).
 * @return {ol.Coordinate} New point 1 px farther from the centroid.
 * @private
 */
ol.reproj.enlargeClipPoint_ = function(centroidX, centroidY, x, y) {
  var dX = x - centroidX, dY = y - centroidY;
  var distance = Math.sqrt(dX * dX + dY * dY);
  return [Math.round(x + dX / distance), Math.round(y + dY / distance)];
};
 
 
/**
 * Renders the source data into new canvas based on the triangulation.
 *
 * @param {number} width Width of the canvas.
 * @param {number} height Height of the canvas.
 * @param {number} pixelRatio Pixel ratio.
 * @param {number} sourceResolution Source resolution.
 * @param {ol.Extent} sourceExtent Extent of the data source.
 * @param {number} targetResolution Target resolution.
 * @param {ol.Extent} targetExtent Target extent.
 * @param {ol.reproj.Triangulation} triangulation Calculated triangulation.
 * @param {Array.<{extent: ol.Extent,
 *                 image: (HTMLCanvasElement|Image|HTMLVideoElement)}>} sources
 *             Array of sources.
 * @param {number} gutter Gutter of the sources.
 * @param {boolean=} opt_renderEdges Render reprojection edges.
 * @return {HTMLCanvasElement} Canvas with reprojected data.
 */
ol.reproj.render = function(width, height, pixelRatio,
    sourceResolution, sourceExtent, targetResolution, targetExtent,
    triangulation, sources, gutter, opt_renderEdges) {
 
  var context = ol.dom.createCanvasContext2D(Math.round(pixelRatio * width),
                                             Math.round(pixelRatio * height));
 
  if (sources.length === 0) {
    return context.canvas;
  }
 
  context.scale(pixelRatio, pixelRatio);
 
  var sourceDataExtent = ol.extent.createEmpty();
  sources.forEach(function(src, i, arr) {
    ol.extent.extend(sourceDataExtent, src.extent);
  });
 
  var canvasWidthInUnits = ol.extent.getWidth(sourceDataExtent);
  var canvasHeightInUnits = ol.extent.getHeight(sourceDataExtent);
  var stitchContext = ol.dom.createCanvasContext2D(
      Math.round(pixelRatio * canvasWidthInUnits / sourceResolution),
      Math.round(pixelRatio * canvasHeightInUnits / sourceResolution));
 
  var stitchScale = pixelRatio / sourceResolution;
 
  sources.forEach(function(src, i, arr) {
    var xPos = src.extent[0] - sourceDataExtent[0];
    var yPos = -(src.extent[3] - sourceDataExtent[3]);
    var srcWidth = ol.extent.getWidth(src.extent);
    var srcHeight = ol.extent.getHeight(src.extent);
 
    stitchContext.drawImage(
        src.image,
        gutter, gutter,
        src.image.width - 2 * gutter, src.image.height - 2 * gutter,
        xPos * stitchScale, yPos * stitchScale,
        srcWidth * stitchScale, srcHeight * stitchScale);
  });
 
  var targetTopLeft = ol.extent.getTopLeft(targetExtent);
 
  triangulation.getTriangles().forEach(function(triangle, i, arr) {
    /* Calculate affine transform (src -> dst)
     * Resulting matrix can be used to transform coordinate
     * from `sourceProjection` to destination pixels.
     *
     * To optimize number of context calls and increase numerical stability,
     * we also do the following operations:
     * trans(-topLeftExtentCorner), scale(1 / targetResolution), scale(1, -1)
     * here before solving the linear system so [ui, vi] are pixel coordinates.
     *
     * Src points: xi, yi
     * Dst points: ui, vi
     * Affine coefficients: aij
     *
     * | x0 y0 1  0  0 0 |   |a00|   |u0|
     * | x1 y1 1  0  0 0 |   |a01|   |u1|
     * | x2 y2 1  0  0 0 | x |a02| = |u2|
     * |  0  0 0 x0 y0 1 |   |a10|   |v0|
     * |  0  0 0 x1 y1 1 |   |a11|   |v1|
     * |  0  0 0 x2 y2 1 |   |a12|   |v2|
     */
    var source = triangle.source, target = triangle.target;
    var x0 = source[0][0], y0 = source[0][1],
        x1 = source[1][0], y1 = source[1][1],
        x2 = source[2][0], y2 = source[2][1];
    var u0 = (target[0][0] - targetTopLeft[0]) / targetResolution,
        v0 = -(target[0][1] - targetTopLeft[1]) / targetResolution;
    var u1 = (target[1][0] - targetTopLeft[0]) / targetResolution,
        v1 = -(target[1][1] - targetTopLeft[1]) / targetResolution;
    var u2 = (target[2][0] - targetTopLeft[0]) / targetResolution,
        v2 = -(target[2][1] - targetTopLeft[1]) / targetResolution;
 
    // Shift all the source points to improve numerical stability
    // of all the subsequent calculations. The [x0, y0] is used here.
    // This is also used to simplify the linear system.
    var sourceNumericalShiftX = x0, sourceNumericalShiftY = y0;
    x0 = 0;
    y0 = 0;
    x1 -= sourceNumericalShiftX;
    y1 -= sourceNumericalShiftY;
    x2 -= sourceNumericalShiftX;
    y2 -= sourceNumericalShiftY;
 
    var augmentedMatrix = [
      [x1, y1, 0, 0, u1 - u0],
      [x2, y2, 0, 0, u2 - u0],
      [0, 0, x1, y1, v1 - v0],
      [0, 0, x2, y2, v2 - v0]
    ];
    var affineCoefs = ol.math.solveLinearSystem(augmentedMatrix);
    if (!affineCoefs) {
      return;
    }
 
    context.save();
    context.beginPath();
    var centroidX = (u0 + u1 + u2) / 3, centroidY = (v0 + v1 + v2) / 3;
    var p0 = ol.reproj.enlargeClipPoint_(centroidX, centroidY, u0, v0);
    var p1 = ol.reproj.enlargeClipPoint_(centroidX, centroidY, u1, v1);
    var p2 = ol.reproj.enlargeClipPoint_(centroidX, centroidY, u2, v2);
 
    context.moveTo(p1[0], p1[1]);
    context.lineTo(p0[0], p0[1]);
    context.lineTo(p2[0], p2[1]);
    context.clip();
 
    context.transform(
        affineCoefs[0], affineCoefs[2], affineCoefs[1], affineCoefs[3], u0, v0);
 
    context.translate(sourceDataExtent[0] - sourceNumericalShiftX,
                      sourceDataExtent[3] - sourceNumericalShiftY);
 
    context.scale(sourceResolution / pixelRatio,
                  -sourceResolution / pixelRatio);
 
    context.drawImage(stitchContext.canvas, 0, 0);
    context.restore();
  });
 
  if (opt_renderEdges) {
    context.save();
 
    context.strokeStyle = 'black';
    context.lineWidth = 1;
 
    triangulation.getTriangles().forEach(function(triangle, i, arr) {
      var target = triangle.target;
      var u0 = (target[0][0] - targetTopLeft[0]) / targetResolution,
          v0 = -(target[0][1] - targetTopLeft[1]) / targetResolution;
      var u1 = (target[1][0] - targetTopLeft[0]) / targetResolution,
          v1 = -(target[1][1] - targetTopLeft[1]) / targetResolution;
      var u2 = (target[2][0] - targetTopLeft[0]) / targetResolution,
          v2 = -(target[2][1] - targetTopLeft[1]) / targetResolution;
 
      context.beginPath();
      context.moveTo(u1, v1);
      context.lineTo(u0, v0);
      context.lineTo(u2, v2);
      context.closePath();
      context.stroke();
    });
 
    context.restore();
  }
  return context.canvas;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/resolutionconstraint.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/resolutionconstraint.js

Statements: 4.17% (1 / 24)      Branches: 0% (0 / 10)      Functions: 0% (0 / 4)      Lines: 4.17% (1 / 24)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 682                                                                                                                                      
goog.provide('ol.ResolutionConstraint');
 
goog.require('ol.array');
goog.require('ol.math');
 
 
/**
 * @param {Array.<number>} resolutions Resolutions.
 * @return {ol.ResolutionConstraintType} Zoom function.
 */
ol.ResolutionConstraint.createSnapToResolutions = function(resolutions) {
  return (
      /**
       * @param {number|undefined} resolution Resolution.
       * @param {number} delta Delta.
       * @param {number} direction Direction.
       * @return {number|undefined} Resolution.
       */
      function(resolution, delta, direction) {
        if (resolution !== undefined) {
          var z =
              ol.array.linearFindNearest(resolutions, resolution, direction);
          z = ol.math.clamp(z + delta, 0, resolutions.length - 1);
          var index = Math.floor(z);
          if (z != index && index < resolutions.length - 1) {
            var power = resolutions[index] / resolutions[index + 1];
            return resolutions[index] / Math.pow(power, z - index);
          } else {
            return resolutions[index];
          }
        } else {
          return undefined;
        }
      });
};
 
 
/**
 * @param {number} power Power.
 * @param {number} maxResolution Maximum resolution.
 * @param {number=} opt_maxLevel Maximum level.
 * @return {ol.ResolutionConstraintType} Zoom function.
 */
ol.ResolutionConstraint.createSnapToPower = function(power, maxResolution, opt_maxLevel) {
  return (
      /**
       * @param {number|undefined} resolution Resolution.
       * @param {number} delta Delta.
       * @param {number} direction Direction.
       * @return {number|undefined} Resolution.
       */
      function(resolution, delta, direction) {
        if (resolution !== undefined) {
          var offset = -direction / 2 + 0.5;
          var oldLevel = Math.floor(
              Math.log(maxResolution / resolution) / Math.log(power) + offset);
          var newLevel = Math.max(oldLevel + delta, 0);
          if (opt_maxLevel !== undefined) {
            newLevel = Math.min(newLevel, opt_maxLevel);
          }
          return maxResolution / Math.pow(power, newLevel);
        } else {
          return undefined;
        }
      });
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/rotationconstraint.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/rotationconstraint.js

Statements: 4% (1 / 25)      Branches: 0% (0 / 12)      Functions: 0% (0 / 6)      Lines: 4% (1 / 25)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 822                                                                                                                                                                  
goog.provide('ol.RotationConstraint');
 
goog.require('ol.math');
 
 
/**
 * @param {number|undefined} rotation Rotation.
 * @param {number} delta Delta.
 * @return {number|undefined} Rotation.
 */
ol.RotationConstraint.disable = function(rotation, delta) {
  if (rotation !== undefined) {
    return 0;
  } else {
    return undefined;
  }
};
 
 
/**
 * @param {number|undefined} rotation Rotation.
 * @param {number} delta Delta.
 * @return {number|undefined} Rotation.
 */
ol.RotationConstraint.none = function(rotation, delta) {
  if (rotation !== undefined) {
    return rotation + delta;
  } else {
    return undefined;
  }
};
 
 
/**
 * @param {number} n N.
 * @return {ol.RotationConstraintType} Rotation constraint.
 */
ol.RotationConstraint.createSnapToN = function(n) {
  var theta = 2 * Math.PI / n;
  return (
      /**
       * @param {number|undefined} rotation Rotation.
       * @param {number} delta Delta.
       * @return {number|undefined} Rotation.
       */
      function(rotation, delta) {
        if (rotation !== undefined) {
          rotation = Math.floor((rotation + delta) / theta + 0.5) * theta;
          return rotation;
        } else {
          return undefined;
        }
      });
};
 
 
/**
 * @param {number=} opt_tolerance Tolerance.
 * @return {ol.RotationConstraintType} Rotation constraint.
 */
ol.RotationConstraint.createSnapToZero = function(opt_tolerance) {
  var tolerance = opt_tolerance || ol.math.toRadians(5);
  return (
      /**
       * @param {number|undefined} rotation Rotation.
       * @param {number} delta Delta.
       * @return {number|undefined} Rotation.
       */
      function(rotation, delta) {
        if (rotation !== undefined) {
          if (Math.abs(rotation + delta) <= tolerance) {
            return 0;
          } else {
            return rotation + delta;
          }
        } else {
          return undefined;
        }
      });
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/size.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/size.js

Statements: 4.55% (1 / 22)      Branches: 0% (0 / 10)      Functions: 0% (0 / 4)      Lines: 4.55% (1 / 22)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 702                                                                                                                                          
goog.provide('ol.size');
 
 
/**
 * Returns a buffered size.
 * @param {ol.Size} size Size.
 * @param {number} buffer Buffer.
 * @param {ol.Size=} opt_size Optional reusable size array.
 * @return {ol.Size} The buffered size.
 */
ol.size.buffer = function(size, buffer, opt_size) {
  if (opt_size === undefined) {
    opt_size = [0, 0];
  }
  opt_size[0] = size[0] + 2 * buffer;
  opt_size[1] = size[1] + 2 * buffer;
  return opt_size;
};
 
 
/**
 * Determines if a size has a positive area.
 * @param {ol.Size} size The size to test.
 * @return {boolean} The size has a positive area.
 */
ol.size.hasArea = function(size) {
  return size[0] > 0 && size[1] > 0;
};
 
 
/**
 * Returns a size scaled by a ratio. The result will be an array of integers.
 * @param {ol.Size} size Size.
 * @param {number} ratio Ratio.
 * @param {ol.Size=} opt_size Optional reusable size array.
 * @return {ol.Size} The scaled size.
 */
ol.size.scale = function(size, ratio, opt_size) {
  if (opt_size === undefined) {
    opt_size = [0, 0];
  }
  opt_size[0] = (size[0] * ratio + 0.5) | 0;
  opt_size[1] = (size[1] * ratio + 0.5) | 0;
  return opt_size;
};
 
 
/**
 * Returns an `ol.Size` array for the passed in number (meaning: square) or
 * `ol.Size` array.
 * (meaning: non-square),
 * @param {number|ol.Size} size Width and height.
 * @param {ol.Size=} opt_size Optional reusable size array.
 * @return {ol.Size} Size.
 * @api
 */
ol.size.toSize = function(size, opt_size) {
  if (Array.isArray(size)) {
    return size;
  } else {
    if (opt_size === undefined) {
      opt_size = [size, size];
    } else {
      opt_size[0] = opt_size[1] = /** @type {number} */ (size);
    }
    return opt_size;
  }
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/sphere.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/sphere.js

Statements: 3.57% (1 / 28)      Branches: 100% (0 / 0)      Functions: 0% (0 / 4)      Lines: 3.57% (1 / 28)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111              2                                                                                                                                                                                                              
/**
 * @license
 * Latitude/longitude spherical geodesy formulae taken from
 * http://www.movable-type.co.uk/scripts/latlong.html
 * Licensed under CC-BY-3.0.
 */
 
goog.provide('ol.Sphere');
 
goog.require('ol.math');
 
 
/**
 * @classdesc
 * Class to create objects that can be used with {@link
 * ol.geom.Polygon.circular}.
 *
 * For example to create a sphere whose radius is equal to the semi-major
 * axis of the WGS84 ellipsoid:
 *
 * ```js
 * var wgs84Sphere= new ol.Sphere(6378137);
 * ```
 *
 * @constructor
 * @param {number} radius Radius.
 * @api
 */
ol.Sphere = function(radius) {
 
  /**
   * @type {number}
   */
  this.radius = radius;
 
};
 
 
/**
 * Returns the geodesic area for a list of coordinates.
 *
 * [Reference](https://trs-new.jpl.nasa.gov/handle/2014/40409)
 * Robert. G. Chamberlain and William H. Duquette, "Some Algorithms for
 * Polygons on a Sphere", JPL Publication 07-03, Jet Propulsion
 * Laboratory, Pasadena, CA, June 2007
 *
 * @param {Array.<ol.Coordinate>} coordinates List of coordinates of a linear
 * ring. If the ring is oriented clockwise, the area will be positive,
 * otherwise it will be negative.
 * @return {number} Area.
 * @api
 */
ol.Sphere.prototype.geodesicArea = function(coordinates) {
  var area = 0, len = coordinates.length;
  var x1 = coordinates[len - 1][0];
  var y1 = coordinates[len - 1][1];
  for (var i = 0; i < len; i++) {
    var x2 = coordinates[i][0], y2 = coordinates[i][1];
    area += ol.math.toRadians(x2 - x1) *
        (2 + Math.sin(ol.math.toRadians(y1)) +
        Math.sin(ol.math.toRadians(y2)));
    x1 = x2;
    y1 = y2;
  }
  return area * this.radius * this.radius / 2.0;
};
 
 
/**
 * Returns the distance from c1 to c2 using the haversine formula.
 *
 * @param {ol.Coordinate} c1 Coordinate 1.
 * @param {ol.Coordinate} c2 Coordinate 2.
 * @return {number} Haversine distance.
 * @api
 */
ol.Sphere.prototype.haversineDistance = function(c1, c2) {
  var lat1 = ol.math.toRadians(c1[1]);
  var lat2 = ol.math.toRadians(c2[1]);
  var deltaLatBy2 = (lat2 - lat1) / 2;
  var deltaLonBy2 = ol.math.toRadians(c2[0] - c1[0]) / 2;
  var a = Math.sin(deltaLatBy2) * Math.sin(deltaLatBy2) +
      Math.sin(deltaLonBy2) * Math.sin(deltaLonBy2) *
      Math.cos(lat1) * Math.cos(lat2);
  return 2 * this.radius * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));
};
 
 
/**
 * Returns the coordinate at the given distance and bearing from `c1`.
 *
 * @param {ol.Coordinate} c1 The origin point (`[lon, lat]` in degrees).
 * @param {number} distance The great-circle distance between the origin
 *     point and the target point.
 * @param {number} bearing The bearing (in radians).
 * @return {ol.Coordinate} The target point.
 */
ol.Sphere.prototype.offset = function(c1, distance, bearing) {
  var lat1 = ol.math.toRadians(c1[1]);
  var lon1 = ol.math.toRadians(c1[0]);
  var dByR = distance / this.radius;
  var lat = Math.asin(
      Math.sin(lat1) * Math.cos(dByR) +
      Math.cos(lat1) * Math.sin(dByR) * Math.cos(bearing));
  var lon = lon1 + Math.atan2(
      Math.sin(bearing) * Math.sin(dByR) * Math.cos(lat1),
      Math.cos(dByR) - Math.sin(lat1) * Math.sin(lat));
  return [ol.math.toDegrees(lon), ol.math.toDegrees(lat)];
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/string.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/string.js

Statements: 5.88% (1 / 17)      Branches: 0% (0 / 14)      Functions: 0% (0 / 2)      Lines: 5.88% (1 / 17)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 412                                                                                
goog.provide('ol.string');
 
/**
 * @param {number} number Number to be formatted
 * @param {number} width The desired width
 * @param {number=} opt_precision Precision of the output string (i.e. number of decimal places)
 * @returns {string} Formatted string
*/
ol.string.padNumber = function(number, width, opt_precision) {
  var numberString = opt_precision !== undefined ? number.toFixed(opt_precision) : '' + number;
  var decimal = numberString.indexOf('.');
  decimal = decimal === -1 ? numberString.length : decimal;
  return decimal > width ? numberString : new Array(1 + width - decimal).join('0') + numberString;
};
 
/**
 * Adapted from https://github.com/omichelsen/compare-versions/blob/master/index.js
 * @param {string|number} v1 First version
 * @param {string|number} v2 Second version
 * @returns {number} Value
 */
ol.string.compareVersions = function(v1, v2) {
  var s1 = ('' + v1).split('.');
  var s2 = ('' + v2).split('.');
 
  for (var i = 0; i < Math.max(s1.length, s2.length); i++) {
    var n1 = parseInt(s1[i] || '0', 10);
    var n2 = parseInt(s2[i] || '0', 10);
 
    if (n1 > n2) {
      return 1;
    }
    if (n2 > n1) {
      return -1;
    }
  }
 
  return 0;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/style.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/style.js

Statements: 33.33% (1 / 3)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 33.33% (1 / 3)      Ignored: none     

1 2 3 4 5 6 72            
goog.provide('ol.style');
 
goog.require('ol.style.IconImageCache');
 
ol.style.iconImageCache = new ol.style.IconImageCache();
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tile.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tile.js

Statements: 2.17% (1 / 46)      Branches: 0% (0 / 12)      Functions: 0% (0 / 9)      Lines: 2.17% (1 / 46)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 1662                                                                                                                                                                                                                                                                                                                                          
goog.provide('ol.Tile');
 
goog.require('ol');
goog.require('ol.TileState');
goog.require('ol.events.EventTarget');
goog.require('ol.events.EventType');
 
 
/**
 * @classdesc
 * Base class for tiles.
 *
 * @constructor
 * @abstract
 * @extends {ol.events.EventTarget}
 * @param {ol.TileCoord} tileCoord Tile coordinate.
 * @param {ol.TileState} state State.
 */
ol.Tile = function(tileCoord, state) {
 
  ol.events.EventTarget.call(this);
 
  /**
   * @type {ol.TileCoord}
   */
  this.tileCoord = tileCoord;
 
  /**
   * @protected
   * @type {ol.TileState}
   */
  this.state = state;
 
  /**
   * An "interim" tile for this tile. The interim tile may be used while this
   * one is loading, for "smooth" transitions when changing params/dimensions
   * on the source.
   * @type {ol.Tile}
   */
  this.interimTile = null;
 
  /**
   * A key assigned to the tile. This is used by the tile source to determine
   * if this tile can effectively be used, or if a new tile should be created
   * and this one be used as an interim tile for this new tile.
   * @type {string}
   */
  this.key = '';
 
};
ol.inherits(ol.Tile, ol.events.EventTarget);
 
 
/**
 * @protected
 */
ol.Tile.prototype.changed = function() {
  this.dispatchEvent(ol.events.EventType.CHANGE);
};
 
 
/**
 * Get the HTML image element for this tile (may be a Canvas, Image, or Video).
 * @abstract
 * @return {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} Image.
 */
ol.Tile.prototype.getImage = function() {};
 
 
/**
 * @return {string} Key.
 */
ol.Tile.prototype.getKey = function() {
  return this.key + '/' + this.tileCoord;
};
 
/**
 * Get the interim tile most suitable for rendering using the chain of interim
 * tiles. This corresponds to the  most recent tile that has been loaded, if no
 * such tile exists, the original tile is returned.
 * @return {!ol.Tile} Best tile for rendering.
 */
ol.Tile.prototype.getInterimTile = function() {
  if (!this.interimTile) {
    //empty chain
    return this;
  }
  var tile = this.interimTile;
 
  // find the first loaded tile and return it. Since the chain is sorted in
  // decreasing order of creation time, there is no need to search the remainder
  // of the list (all those tiles correspond to older requests and will be
  // cleaned up by refreshInterimChain)
  do {
    if (tile.getState() == ol.TileState.LOADED) {
      return tile;
    }
    tile = tile.interimTile;
  } while (tile);
 
  // we can not find a better tile
  return this;
};
 
/**
 * Goes through the chain of interim tiles and discards sections of the chain
 * that are no longer relevant.
 */
ol.Tile.prototype.refreshInterimChain = function() {
  if (!this.interimTile) {
    return;
  }
 
  var tile = this.interimTile;
  var prev = this;
 
  do {
    if (tile.getState() == ol.TileState.LOADED) {
      //we have a loaded tile, we can discard the rest of the list
      //we would could abort any LOADING tile request
      //older than this tile (i.e. any LOADING tile following this entry in the chain)
      tile.interimTile = null;
      break;
    } else if (tile.getState() == ol.TileState.LOADING) {
      //keep this LOADING tile any loaded tiles later in the chain are
      //older than this tile, so we're still interested in the request
      prev = tile;
    } else if (tile.getState() == ol.TileState.IDLE) {
      //the head of the list is the most current tile, we don't need
      //to start any other requests for this chain
      prev.interimTile = tile.interimTile;
    } else {
      prev = tile;
    }
    tile = prev.interimTile;
  } while (tile);
};
 
/**
 * Get the tile coordinate for this tile.
 * @return {ol.TileCoord} The tile coordinate.
 * @api
 */
ol.Tile.prototype.getTileCoord = function() {
  return this.tileCoord;
};
 
 
/**
 * @return {ol.TileState} State.
 */
ol.Tile.prototype.getState = function() {
  return this.state;
};
 
 
/**
 * Load the image or retry if loading previously failed.
 * Loading is taken care of by the tile queue, and calling this method is
 * only needed for preloading or for reloading in case of an error.
 * @abstract
 * @api
 */
ol.Tile.prototype.load = function() {};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilecache.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilecache.js

Statements: 5.88% (1 / 17)      Branches: 0% (0 / 6)      Functions: 0% (0 / 3)      Lines: 5.88% (1 / 17)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 502                                                                                                  
goog.provide('ol.TileCache');
 
goog.require('ol');
goog.require('ol.structs.LRUCache');
 
 
/**
 * @constructor
 * @extends {ol.structs.LRUCache.<ol.Tile>}
 * @param {number=} opt_highWaterMark High water mark.
 * @struct
 */
ol.TileCache = function(opt_highWaterMark) {
 
  ol.structs.LRUCache.call(this);
 
  /**
   * @type {number}
   */
  this.highWaterMark = opt_highWaterMark !== undefined ? opt_highWaterMark : 2048;
 
};
ol.inherits(ol.TileCache, ol.structs.LRUCache);
 
 
/**
 * @return {boolean} Can expire cache.
 */
ol.TileCache.prototype.canExpireCache = function() {
  return this.getCount() > this.highWaterMark;
};
 
 
/**
 * @param {Object.<string, ol.TileRange>} usedTiles Used tiles.
 */
ol.TileCache.prototype.expireCache = function(usedTiles) {
  var tile, zKey;
  while (this.canExpireCache()) {
    tile = this.peekLast();
    zKey = tile.tileCoord[0].toString();
    if (zKey in usedTiles && usedTiles[zKey].contains(tile.tileCoord)) {
      break;
    } else {
      this.pop().dispose();
    }
  }
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilecoord.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilecoord.js

Statements: 2.5% (1 / 40)      Branches: 0% (0 / 14)      Functions: 0% (0 / 5)      Lines: 2.5% (1 / 40)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 952                                                                                                                                                                                            
goog.provide('ol.tilecoord');
 
 
/**
 * @param {number} z Z.
 * @param {number} x X.
 * @param {number} y Y.
 * @param {ol.TileCoord=} opt_tileCoord Tile coordinate.
 * @return {ol.TileCoord} Tile coordinate.
 */
ol.tilecoord.createOrUpdate = function(z, x, y, opt_tileCoord) {
  if (opt_tileCoord !== undefined) {
    opt_tileCoord[0] = z;
    opt_tileCoord[1] = x;
    opt_tileCoord[2] = y;
    return opt_tileCoord;
  } else {
    return [z, x, y];
  }
};
 
 
/**
 * @param {number} z Z.
 * @param {number} x X.
 * @param {number} y Y.
 * @return {string} Key.
 */
ol.tilecoord.getKeyZXY = function(z, x, y) {
  return z + '/' + x + '/' + y;
};
 
 
/**
 * @param {ol.TileCoord} tileCoord Tile coord.
 * @return {number} Hash.
 */
ol.tilecoord.hash = function(tileCoord) {
  return (tileCoord[1] << tileCoord[0]) + tileCoord[2];
};
 
 
/**
 * @param {ol.TileCoord} tileCoord Tile coord.
 * @return {string} Quad key.
 */
ol.tilecoord.quadKey = function(tileCoord) {
  var z = tileCoord[0];
  var digits = new Array(z);
  var mask = 1 << (z - 1);
  var i, charCode;
  for (i = 0; i < z; ++i) {
    // 48 is charCode for 0 - '0'.charCodeAt(0)
    charCode = 48;
    if (tileCoord[1] & mask) {
      charCode += 1;
    }
    if (tileCoord[2] & mask) {
      charCode += 2;
    }
    digits[i] = String.fromCharCode(charCode);
    mask >>= 1;
  }
  return digits.join('');
};
 
 
/**
 * @param {ol.TileCoord} tileCoord Tile coordinate.
 * @param {!ol.tilegrid.TileGrid} tileGrid Tile grid.
 * @return {boolean} Tile coordinate is within extent and zoom level range.
 */
ol.tilecoord.withinExtentAndZ = function(tileCoord, tileGrid) {
  var z = tileCoord[0];
  var x = tileCoord[1];
  var y = tileCoord[2];
 
  if (tileGrid.getMinZoom() > z || z > tileGrid.getMaxZoom()) {
    return false;
  }
  var extent = tileGrid.getExtent();
  var tileRange;
  if (!extent) {
    tileRange = tileGrid.getFullTileRange(z);
  } else {
    tileRange = tileGrid.getTileRangeForExtentAndZ(extent, z);
  }
  if (!tileRange) {
    return true;
  } else {
    return tileRange.containsXY(x, y);
  }
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilegrid.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilegrid.js

Statements: 1.72% (1 / 58)      Branches: 0% (0 / 16)      Functions: 0% (0 / 7)      Lines: 1.72% (1 / 58)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 1582                                                                                                                                                                                                                                                                                                                          
goog.provide('ol.tilegrid');
 
goog.require('ol');
goog.require('ol.size');
goog.require('ol.extent');
goog.require('ol.extent.Corner');
goog.require('ol.obj');
goog.require('ol.proj');
goog.require('ol.proj.Units');
goog.require('ol.tilegrid.TileGrid');
 
 
/**
 * @param {ol.proj.Projection} projection Projection.
 * @return {!ol.tilegrid.TileGrid} Default tile grid for the passed projection.
 */
ol.tilegrid.getForProjection = function(projection) {
  var tileGrid = projection.getDefaultTileGrid();
  if (!tileGrid) {
    tileGrid = ol.tilegrid.createForProjection(projection);
    projection.setDefaultTileGrid(tileGrid);
  }
  return tileGrid;
};
 
 
/**
 * @param {ol.tilegrid.TileGrid} tileGrid Tile grid.
 * @param {ol.TileCoord} tileCoord Tile coordinate.
 * @param {ol.proj.Projection} projection Projection.
 * @return {ol.TileCoord} Tile coordinate.
 */
ol.tilegrid.wrapX = function(tileGrid, tileCoord, projection) {
  var z = tileCoord[0];
  var center = tileGrid.getTileCoordCenter(tileCoord);
  var projectionExtent = ol.tilegrid.extentFromProjection(projection);
  if (!ol.extent.containsCoordinate(projectionExtent, center)) {
    var worldWidth = ol.extent.getWidth(projectionExtent);
    var worldsAway = Math.ceil((projectionExtent[0] - center[0]) / worldWidth);
    center[0] += worldWidth * worldsAway;
    return tileGrid.getTileCoordForCoordAndZ(center, z);
  } else {
    return tileCoord;
  }
};
 
 
/**
 * @param {ol.Extent} extent Extent.
 * @param {number=} opt_maxZoom Maximum zoom level (default is
 *     ol.DEFAULT_MAX_ZOOM).
 * @param {number|ol.Size=} opt_tileSize Tile size (default uses
 *     ol.DEFAULT_TILE_SIZE).
 * @param {ol.extent.Corner=} opt_corner Extent corner (default is
 *     ol.extent.Corner.TOP_LEFT).
 * @return {!ol.tilegrid.TileGrid} TileGrid instance.
 */
ol.tilegrid.createForExtent = function(extent, opt_maxZoom, opt_tileSize, opt_corner) {
  var corner = opt_corner !== undefined ?
      opt_corner : ol.extent.Corner.TOP_LEFT;
 
  var resolutions = ol.tilegrid.resolutionsFromExtent(
      extent, opt_maxZoom, opt_tileSize);
 
  return new ol.tilegrid.TileGrid({
    extent: extent,
    origin: ol.extent.getCorner(extent, corner),
    resolutions: resolutions,
    tileSize: opt_tileSize
  });
};
 
 
/**
 * Creates a tile grid with a standard XYZ tiling scheme.
 * @param {olx.tilegrid.XYZOptions=} opt_options Tile grid options.
 * @return {ol.tilegrid.TileGrid} Tile grid instance.
 * @api
 */
ol.tilegrid.createXYZ = function(opt_options) {
  var options = /** @type {olx.tilegrid.TileGridOptions} */ ({});
  ol.obj.assign(options, opt_options !== undefined ?
      opt_options : /** @type {olx.tilegrid.XYZOptions} */ ({}));
  if (options.extent === undefined) {
    options.extent = ol.proj.get('EPSG:3857').getExtent();
  }
  options.resolutions = ol.tilegrid.resolutionsFromExtent(
      options.extent, options.maxZoom, options.tileSize);
  delete options.maxZoom;
 
  return new ol.tilegrid.TileGrid(options);
};
 
 
/**
 * Create a resolutions array from an extent.  A zoom factor of 2 is assumed.
 * @param {ol.Extent} extent Extent.
 * @param {number=} opt_maxZoom Maximum zoom level (default is
 *     ol.DEFAULT_MAX_ZOOM).
 * @param {number|ol.Size=} opt_tileSize Tile size (default uses
 *     ol.DEFAULT_TILE_SIZE).
 * @return {!Array.<number>} Resolutions array.
 */
ol.tilegrid.resolutionsFromExtent = function(extent, opt_maxZoom, opt_tileSize) {
  var maxZoom = opt_maxZoom !== undefined ?
      opt_maxZoom : ol.DEFAULT_MAX_ZOOM;
 
  var height = ol.extent.getHeight(extent);
  var width = ol.extent.getWidth(extent);
 
  var tileSize = ol.size.toSize(opt_tileSize !== undefined ?
      opt_tileSize : ol.DEFAULT_TILE_SIZE);
  var maxResolution = Math.max(
      width / tileSize[0], height / tileSize[1]);
 
  var length = maxZoom + 1;
  var resolutions = new Array(length);
  for (var z = 0; z < length; ++z) {
    resolutions[z] = maxResolution / Math.pow(2, z);
  }
  return resolutions;
};
 
 
/**
 * @param {ol.ProjectionLike} projection Projection.
 * @param {number=} opt_maxZoom Maximum zoom level (default is
 *     ol.DEFAULT_MAX_ZOOM).
 * @param {ol.Size=} opt_tileSize Tile size (default uses ol.DEFAULT_TILE_SIZE).
 * @param {ol.extent.Corner=} opt_corner Extent corner (default is
 *     ol.extent.Corner.BOTTOM_LEFT).
 * @return {!ol.tilegrid.TileGrid} TileGrid instance.
 */
ol.tilegrid.createForProjection = function(projection, opt_maxZoom, opt_tileSize, opt_corner) {
  var extent = ol.tilegrid.extentFromProjection(projection);
  return ol.tilegrid.createForExtent(
      extent, opt_maxZoom, opt_tileSize, opt_corner);
};
 
 
/**
 * Generate a tile grid extent from a projection.  If the projection has an
 * extent, it is used.  If not, a global extent is assumed.
 * @param {ol.ProjectionLike} projection Projection.
 * @return {ol.Extent} Extent.
 */
ol.tilegrid.extentFromProjection = function(projection) {
  projection = ol.proj.get(projection);
  var extent = projection.getExtent();
  if (!extent) {
    var half = 180 * ol.proj.METERS_PER_UNIT[ol.proj.Units.DEGREES] /
        projection.getMetersPerUnit();
    extent = ol.extent.createOrUpdate(-half, -half, half, half);
  }
  return extent;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilequeue.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilequeue.js

Statements: 2.33% (1 / 43)      Branches: 0% (0 / 17)      Functions: 0% (0 / 7)      Lines: 2.33% (1 / 43)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 1232                                                                                                                                                                                                                                                    
goog.provide('ol.TileQueue');
 
goog.require('ol');
goog.require('ol.TileState');
goog.require('ol.events');
goog.require('ol.events.EventType');
goog.require('ol.structs.PriorityQueue');
 
 
/**
 * @constructor
 * @extends {ol.structs.PriorityQueue.<Array>}
 * @param {ol.TilePriorityFunction} tilePriorityFunction
 *     Tile priority function.
 * @param {function(): ?} tileChangeCallback
 *     Function called on each tile change event.
 * @struct
 */
ol.TileQueue = function(tilePriorityFunction, tileChangeCallback) {
 
  ol.structs.PriorityQueue.call(
      this,
      /**
       * @param {Array} element Element.
       * @return {number} Priority.
       */
      function(element) {
        return tilePriorityFunction.apply(null, element);
      },
      /**
       * @param {Array} element Element.
       * @return {string} Key.
       */
      function(element) {
        return /** @type {ol.Tile} */ (element[0]).getKey();
      });
 
  /**
   * @private
   * @type {function(): ?}
   */
  this.tileChangeCallback_ = tileChangeCallback;
 
  /**
   * @private
   * @type {number}
   */
  this.tilesLoading_ = 0;
 
  /**
   * @private
   * @type {!Object.<string,boolean>}
   */
  this.tilesLoadingKeys_ = {};
 
};
ol.inherits(ol.TileQueue, ol.structs.PriorityQueue);
 
 
/**
 * @inheritDoc
 */
ol.TileQueue.prototype.enqueue = function(element) {
  var added = ol.structs.PriorityQueue.prototype.enqueue.call(this, element);
  if (added) {
    var tile = element[0];
    ol.events.listen(tile, ol.events.EventType.CHANGE,
        this.handleTileChange, this);
  }
  return added;
};
 
 
/**
 * @return {number} Number of tiles loading.
 */
ol.TileQueue.prototype.getTilesLoading = function() {
  return this.tilesLoading_;
};
 
 
/**
 * @param {ol.events.Event} event Event.
 * @protected
 */
ol.TileQueue.prototype.handleTileChange = function(event) {
  var tile = /** @type {ol.Tile} */ (event.target);
  var state = tile.getState();
  if (state === ol.TileState.LOADED || state === ol.TileState.ERROR ||
      state === ol.TileState.EMPTY || state === ol.TileState.ABORT) {
    ol.events.unlisten(tile, ol.events.EventType.CHANGE,
        this.handleTileChange, this);
    var tileKey = tile.getKey();
    if (tileKey in this.tilesLoadingKeys_) {
      delete this.tilesLoadingKeys_[tileKey];
      --this.tilesLoading_;
    }
    this.tileChangeCallback_();
  }
};
 
 
/**
 * @param {number} maxTotalLoading Maximum number tiles to load simultaneously.
 * @param {number} maxNewLoads Maximum number of new tiles to load.
 */
ol.TileQueue.prototype.loadMoreTiles = function(maxTotalLoading, maxNewLoads) {
  var newLoads = 0;
  var tile, tileKey;
  while (this.tilesLoading_ < maxTotalLoading && newLoads < maxNewLoads &&
         this.getCount() > 0) {
    tile = /** @type {ol.Tile} */ (this.dequeue()[0]);
    tileKey = tile.getKey();
    if (tile.getState() === ol.TileState.IDLE && !(tileKey in this.tilesLoadingKeys_)) {
      this.tilesLoadingKeys_[tileKey] = true;
      ++this.tilesLoading_;
      ++newLoads;
      tile.load();
    }
  }
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilerange.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilerange.js

Statements: 2.56% (1 / 39)      Branches: 0% (0 / 26)      Functions: 0% (0 / 11)      Lines: 2.56% (1 / 39)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 1542                                                                                                                                                                                                                                                                                                                  
goog.provide('ol.TileRange');
 
 
/**
 * A representation of a contiguous block of tiles.  A tile range is specified
 * by its min/max tile coordinates and is inclusive of coordinates.
 *
 * @constructor
 * @param {number} minX Minimum X.
 * @param {number} maxX Maximum X.
 * @param {number} minY Minimum Y.
 * @param {number} maxY Maximum Y.
 * @struct
 */
ol.TileRange = function(minX, maxX, minY, maxY) {
 
  /**
   * @type {number}
   */
  this.minX = minX;
 
  /**
   * @type {number}
   */
  this.maxX = maxX;
 
  /**
   * @type {number}
   */
  this.minY = minY;
 
  /**
   * @type {number}
   */
  this.maxY = maxY;
 
};
 
 
/**
 * @param {number} minX Minimum X.
 * @param {number} maxX Maximum X.
 * @param {number} minY Minimum Y.
 * @param {number} maxY Maximum Y.
 * @param {ol.TileRange|undefined} tileRange TileRange.
 * @return {ol.TileRange} Tile range.
 */
ol.TileRange.createOrUpdate = function(minX, maxX, minY, maxY, tileRange) {
  if (tileRange !== undefined) {
    tileRange.minX = minX;
    tileRange.maxX = maxX;
    tileRange.minY = minY;
    tileRange.maxY = maxY;
    return tileRange;
  } else {
    return new ol.TileRange(minX, maxX, minY, maxY);
  }
};
 
 
/**
 * @param {ol.TileCoord} tileCoord Tile coordinate.
 * @return {boolean} Contains tile coordinate.
 */
ol.TileRange.prototype.contains = function(tileCoord) {
  return this.containsXY(tileCoord[1], tileCoord[2]);
};
 
 
/**
 * @param {ol.TileRange} tileRange Tile range.
 * @return {boolean} Contains.
 */
ol.TileRange.prototype.containsTileRange = function(tileRange) {
  return this.minX <= tileRange.minX && tileRange.maxX <= this.maxX &&
      this.minY <= tileRange.minY && tileRange.maxY <= this.maxY;
};
 
 
/**
 * @param {number} x Tile coordinate x.
 * @param {number} y Tile coordinate y.
 * @return {boolean} Contains coordinate.
 */
ol.TileRange.prototype.containsXY = function(x, y) {
  return this.minX <= x && x <= this.maxX && this.minY <= y && y <= this.maxY;
};
 
 
/**
 * @param {ol.TileRange} tileRange Tile range.
 * @return {boolean} Equals.
 */
ol.TileRange.prototype.equals = function(tileRange) {
  return this.minX == tileRange.minX && this.minY == tileRange.minY &&
      this.maxX == tileRange.maxX && this.maxY == tileRange.maxY;
};
 
 
/**
 * @param {ol.TileRange} tileRange Tile range.
 */
ol.TileRange.prototype.extend = function(tileRange) {
  if (tileRange.minX < this.minX) {
    this.minX = tileRange.minX;
  }
  if (tileRange.maxX > this.maxX) {
    this.maxX = tileRange.maxX;
  }
  if (tileRange.minY < this.minY) {
    this.minY = tileRange.minY;
  }
  if (tileRange.maxY > this.maxY) {
    this.maxY = tileRange.maxY;
  }
};
 
 
/**
 * @return {number} Height.
 */
ol.TileRange.prototype.getHeight = function() {
  return this.maxY - this.minY + 1;
};
 
 
/**
 * @return {ol.Size} Size.
 */
ol.TileRange.prototype.getSize = function() {
  return [this.getWidth(), this.getHeight()];
};
 
 
/**
 * @return {number} Width.
 */
ol.TileRange.prototype.getWidth = function() {
  return this.maxX - this.minX + 1;
};
 
 
/**
 * @param {ol.TileRange} tileRange Tile range.
 * @return {boolean} Intersects.
 */
ol.TileRange.prototype.intersects = function(tileRange) {
  return this.minX <= tileRange.maxX &&
      this.maxX >= tileRange.minX &&
      this.minY <= tileRange.maxY &&
      this.maxY >= tileRange.minY;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilestate.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tilestate.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 152                            
goog.provide('ol.TileState');
 
/**
 * @enum {number}
 */
ol.TileState = {
  IDLE: 0,
  LOADING: 1,
  LOADED: 2,
  ERROR: 3,
  EMPTY: 4,
  ABORT: 5
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tileurlfunction.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/tileurlfunction.js

Statements: 1.82% (1 / 55)      Branches: 0% (0 / 10)      Functions: 0% (0 / 9)      Lines: 1.82% (1 / 55)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 1312                                                                                                                                                                                                                                                                    
goog.provide('ol.TileUrlFunction');
 
goog.require('ol.asserts');
goog.require('ol.math');
goog.require('ol.tilecoord');
 
 
/**
 * @param {string} template Template.
 * @param {ol.tilegrid.TileGrid} tileGrid Tile grid.
 * @return {ol.TileUrlFunctionType} Tile URL function.
 */
ol.TileUrlFunction.createFromTemplate = function(template, tileGrid) {
  var zRegEx = /\{z\}/g;
  var xRegEx = /\{x\}/g;
  var yRegEx = /\{y\}/g;
  var dashYRegEx = /\{-y\}/g;
  return (
      /**
       * @param {ol.TileCoord} tileCoord Tile Coordinate.
       * @param {number} pixelRatio Pixel ratio.
       * @param {ol.proj.Projection} projection Projection.
       * @return {string|undefined} Tile URL.
       */
      function(tileCoord, pixelRatio, projection) {
        if (!tileCoord) {
          return undefined;
        } else {
          return template.replace(zRegEx, tileCoord[0].toString())
              .replace(xRegEx, tileCoord[1].toString())
              .replace(yRegEx, function() {
                var y = -tileCoord[2] - 1;
                return y.toString();
              })
              .replace(dashYRegEx, function() {
                var z = tileCoord[0];
                var range = tileGrid.getFullTileRange(z);
                ol.asserts.assert(range, 55); // The {-y} placeholder requires a tile grid with extent
                var y = range.getHeight() + tileCoord[2];
                return y.toString();
              });
        }
      });
};
 
 
/**
 * @param {Array.<string>} templates Templates.
 * @param {ol.tilegrid.TileGrid} tileGrid Tile grid.
 * @return {ol.TileUrlFunctionType} Tile URL function.
 */
ol.TileUrlFunction.createFromTemplates = function(templates, tileGrid) {
  var len = templates.length;
  var tileUrlFunctions = new Array(len);
  for (var i = 0; i < len; ++i) {
    tileUrlFunctions[i] = ol.TileUrlFunction.createFromTemplate(
        templates[i], tileGrid);
  }
  return ol.TileUrlFunction.createFromTileUrlFunctions(tileUrlFunctions);
};
 
 
/**
 * @param {Array.<ol.TileUrlFunctionType>} tileUrlFunctions Tile URL Functions.
 * @return {ol.TileUrlFunctionType} Tile URL function.
 */
ol.TileUrlFunction.createFromTileUrlFunctions = function(tileUrlFunctions) {
  if (tileUrlFunctions.length === 1) {
    return tileUrlFunctions[0];
  }
  return (
      /**
       * @param {ol.TileCoord} tileCoord Tile Coordinate.
       * @param {number} pixelRatio Pixel ratio.
       * @param {ol.proj.Projection} projection Projection.
       * @return {string|undefined} Tile URL.
       */
      function(tileCoord, pixelRatio, projection) {
        if (!tileCoord) {
          return undefined;
        } else {
          var h = ol.tilecoord.hash(tileCoord);
          var index = ol.math.modulo(h, tileUrlFunctions.length);
          return tileUrlFunctions[index](tileCoord, pixelRatio, projection);
        }
      });
};
 
 
/**
 * @param {ol.TileCoord} tileCoord Tile coordinate.
 * @param {number} pixelRatio Pixel ratio.
 * @param {ol.proj.Projection} projection Projection.
 * @return {string|undefined} Tile URL.
 */
ol.TileUrlFunction.nullTileUrlFunction = function(tileCoord, pixelRatio, projection) {
  return undefined;
};
 
 
/**
 * @param {string} url URL.
 * @return {Array.<string>} Array of urls.
 */
ol.TileUrlFunction.expandUrl = function(url) {
  var urls = [];
  var match = /\{([a-z])-([a-z])\}/.exec(url);
  if (match) {
    // char range
    var startCharCode = match[1].charCodeAt(0);
    var stopCharCode = match[2].charCodeAt(0);
    var charCode;
    for (charCode = startCharCode; charCode <= stopCharCode; ++charCode) {
      urls.push(url.replace(match[0], String.fromCharCode(charCode)));
    }
    return urls;
  }
  match = match = /\{(\d+)-(\d+)\}/.exec(url);
  if (match) {
    // number range
    var stop = parseInt(match[2], 10);
    for (var i = parseInt(match[1], 10); i <= stop; i++) {
      urls.push(url.replace(match[0], i.toString()));
    }
    return urls;
  }
  urls.push(url);
  return urls;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/transform.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/transform.js

Statements: 1.19% (1 / 84)      Branches: 100% (0 / 0)      Functions: 0% (0 / 12)      Lines: 1.19% (1 / 84)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 2342                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  
goog.provide('ol.transform');
 
goog.require('ol.asserts');
 
 
/**
 * Collection of affine 2d transformation functions. The functions work on an
 * array of 6 elements. The element order is compatible with the [SVGMatrix
 * interface](https://developer.mozilla.org/en-US/docs/Web/API/SVGMatrix) and is
 * a subset (elements a to f) of a 3x3 martrix:
 * ```
 * [ a c e ]
 * [ b d f ]
 * [ 0 0 1 ]
 * ```
 */
 
 
/**
 * @private
 * @type {ol.Transform}
 */
ol.transform.tmp_ = new Array(6);
 
 
/**
 * Create an identity transform.
 * @return {!ol.Transform} Identity transform.
 */
ol.transform.create = function() {
  return [1, 0, 0, 1, 0, 0];
};
 
 
/**
 * Resets the given transform to an identity transform.
 * @param {!ol.Transform} transform Transform.
 * @return {!ol.Transform} Transform.
 */
ol.transform.reset = function(transform) {
  return ol.transform.set(transform, 1, 0, 0, 1, 0, 0);
};
 
 
/**
 * Multiply the underlying matrices of two transforms and return the result in
 * the first transform.
 * @param {!ol.Transform} transform1 Transform parameters of matrix 1.
 * @param {!ol.Transform} transform2 Transform parameters of matrix 2.
 * @return {!ol.Transform} transform1 multiplied with transform2.
 */
ol.transform.multiply = function(transform1, transform2) {
  var a1 = transform1[0];
  var b1 = transform1[1];
  var c1 = transform1[2];
  var d1 = transform1[3];
  var e1 = transform1[4];
  var f1 = transform1[5];
  var a2 = transform2[0];
  var b2 = transform2[1];
  var c2 = transform2[2];
  var d2 = transform2[3];
  var e2 = transform2[4];
  var f2 = transform2[5];
 
  transform1[0] = a1 * a2 + c1 * b2;
  transform1[1] = b1 * a2 + d1 * b2;
  transform1[2] = a1 * c2 + c1 * d2;
  transform1[3] = b1 * c2 + d1 * d2;
  transform1[4] = a1 * e2 + c1 * f2 + e1;
  transform1[5] = b1 * e2 + d1 * f2 + f1;
 
  return transform1;
};
 
/**
 * Set the transform components a-f on a given transform.
 * @param {!ol.Transform} transform Transform.
 * @param {number} a The a component of the transform.
 * @param {number} b The b component of the transform.
 * @param {number} c The c component of the transform.
 * @param {number} d The d component of the transform.
 * @param {number} e The e component of the transform.
 * @param {number} f The f component of the transform.
 * @return {!ol.Transform} Matrix with transform applied.
 */
ol.transform.set = function(transform, a, b, c, d, e, f) {
  transform[0] = a;
  transform[1] = b;
  transform[2] = c;
  transform[3] = d;
  transform[4] = e;
  transform[5] = f;
  return transform;
};
 
 
/**
 * Set transform on one matrix from another matrix.
 * @param {!ol.Transform} transform1 Matrix to set transform to.
 * @param {!ol.Transform} transform2 Matrix to set transform from.
 * @return {!ol.Transform} transform1 with transform from transform2 applied.
 */
ol.transform.setFromArray = function(transform1, transform2) {
  transform1[0] = transform2[0];
  transform1[1] = transform2[1];
  transform1[2] = transform2[2];
  transform1[3] = transform2[3];
  transform1[4] = transform2[4];
  transform1[5] = transform2[5];
  return transform1;
};
 
 
/**
 * Transforms the given coordinate with the given transform returning the
 * resulting, transformed coordinate. The coordinate will be modified in-place.
 *
 * @param {ol.Transform} transform The transformation.
 * @param {ol.Coordinate|ol.Pixel} coordinate The coordinate to transform.
 * @return {ol.Coordinate|ol.Pixel} return coordinate so that operations can be
 *     chained together.
 */
ol.transform.apply = function(transform, coordinate) {
  var x = coordinate[0], y = coordinate[1];
  coordinate[0] = transform[0] * x + transform[2] * y + transform[4];
  coordinate[1] = transform[1] * x + transform[3] * y + transform[5];
  return coordinate;
};
 
 
/**
 * Applies rotation to the given transform.
 * @param {!ol.Transform} transform Transform.
 * @param {number} angle Angle in radians.
 * @return {!ol.Transform} The rotated transform.
 */
ol.transform.rotate = function(transform, angle) {
  var cos = Math.cos(angle);
  var sin = Math.sin(angle);
  return ol.transform.multiply(transform,
      ol.transform.set(ol.transform.tmp_, cos, sin, -sin, cos, 0, 0));
};
 
 
/**
 * Applies scale to a given transform.
 * @param {!ol.Transform} transform Transform.
 * @param {number} x Scale factor x.
 * @param {number} y Scale factor y.
 * @return {!ol.Transform} The scaled transform.
 */
ol.transform.scale = function(transform, x, y) {
  return ol.transform.multiply(transform,
      ol.transform.set(ol.transform.tmp_, x, 0, 0, y, 0, 0));
};
 
 
/**
 * Applies translation to the given transform.
 * @param {!ol.Transform} transform Transform.
 * @param {number} dx Translation x.
 * @param {number} dy Translation y.
 * @return {!ol.Transform} The translated transform.
 */
ol.transform.translate = function(transform, dx, dy) {
  return ol.transform.multiply(transform,
      ol.transform.set(ol.transform.tmp_, 1, 0, 0, 1, dx, dy));
};
 
 
/**
 * Creates a composite transform given an initial translation, scale, rotation, and
 * final translation (in that order only, not commutative).
 * @param {!ol.Transform} transform The transform (will be modified in place).
 * @param {number} dx1 Initial translation x.
 * @param {number} dy1 Initial translation y.
 * @param {number} sx Scale factor x.
 * @param {number} sy Scale factor y.
 * @param {number} angle Rotation (in counter-clockwise radians).
 * @param {number} dx2 Final translation x.
 * @param {number} dy2 Final translation y.
 * @return {!ol.Transform} The composite transform.
 */
ol.transform.compose = function(transform, dx1, dy1, sx, sy, angle, dx2, dy2) {
  var sin = Math.sin(angle);
  var cos = Math.cos(angle);
  transform[0] = sx * cos;
  transform[1] = sy * sin;
  transform[2] = -sx * sin;
  transform[3] = sy * cos;
  transform[4] = dx2 * sx * cos - dy2 * sx * sin + dx1;
  transform[5] = dx2 * sy * sin + dy2 * sy * cos + dy1;
  return transform;
};
 
 
/**
 * Invert the given transform.
 * @param {!ol.Transform} transform Transform.
 * @return {!ol.Transform} Inverse of the transform.
 */
ol.transform.invert = function(transform) {
  var det = ol.transform.determinant(transform);
  ol.asserts.assert(det !== 0, 32); // Transformation matrix cannot be inverted
 
  var a = transform[0];
  var b = transform[1];
  var c = transform[2];
  var d = transform[3];
  var e = transform[4];
  var f = transform[5];
 
  transform[0] = d / det;
  transform[1] = -b / det;
  transform[2] = -c / det;
  transform[3] = a / det;
  transform[4] = (c * f - d * e) / det;
  transform[5] = -(a * f - b * e) / det;
 
  return transform;
};
 
 
/**
 * Returns the determinant of the given matrix.
 * @param {!ol.Transform} mat Matrix.
 * @return {number} Determinant.
 */
ol.transform.determinant = function(mat) {
  return mat[0] * mat[3] - mat[1] * mat[2];
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/typedefs.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/typedefs.js

Statements: 1.28% (1 / 78)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 1.28% (1 / 78)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778                                          2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        
/* eslint-disable openlayers-internal/no-missing-requires */
 
/**
 * File for all typedefs used by the compiler, and referenced by JSDoc.
 *
 * These look like vars (or var properties), but in fact are simply identifiers
 * for the Closure compiler. Originally they were included in the appropriate
 * namespace file, but with the move away from Closure namespaces and towards
 * self-contained standard modules are now all in this file.
 * Unlike the other type definitions - enums and constructor functions - they
 * are not code and so are not imported or exported. They are only referred to
 * in type-defining comments used by the Closure compiler, and so should not
 * appear in module code.
 *
 * They are now all in the `ol` namespace.
 */
 
 
/**
 * @typedef {{x: number, y: number, width: number, height: number}}
 */
ol.AtlasBlock;
 
 
/**
 * Provides information for an image inside an atlas.
 * `offsetX` and `offsetY` are the position of the image inside
 * the atlas image `image`.
 * @typedef {{offsetX: number, offsetY: number, image: HTMLCanvasElement}}
 */
ol.AtlasInfo;
 
 
/**
 * Provides information for an image inside an atlas manager.
 * `offsetX` and `offsetY` is the position of the image inside
 * the atlas image `image` and the position of the hit-detection image
 * inside the hit-detection atlas image `hitImage`.
 * @typedef {{offsetX: number, offsetY: number, image: HTMLCanvasElement,
 *    hitImage: HTMLCanvasElement}}
 */
ol.AtlasManagerInfo;
 
 
/**
 * A type that can be used to provide attribution information for data sources.
 *
 * It represents either
 * * a simple string (e.g. `'© Acme Inc.'`),
 * * an array of simple strings (e.g. `['© Acme Inc.', '© Bacme Inc.']`),
 * * an instance of `{@link ol.Attribution}`,
 * * or an array with multiple `{@link ol.Attribution}` instances.
 * @typedef {string|Array.<string>|ol.Attribution|Array.<ol.Attribution>}
 */
ol.AttributionLike;
 
 
/**
 * @typedef {{fillStyle: ol.ColorLike}}
 */
ol.CanvasFillState;
 
 
/**
 * A function returning the canvas element (`{HTMLCanvasElement}`)
 * used by the source as an image. The arguments passed to the function are:
 * {@link ol.Extent} the image extent, `{number}` the image resolution,
 * `{number}` the device pixel ratio, {@link ol.Size} the image size, and
 * {@link ol.proj.Projection} the image projection. The canvas returned by
 * this function is cached by the source. The this keyword inside the function
 * references the {@link ol.source.ImageCanvas}.
 *
 * @typedef {function(this:ol.source.ImageCanvas, ol.Extent, number,
 *     number, ol.Size, ol.proj.Projection): HTMLCanvasElement}
 */
ol.CanvasFunctionType;
 
 
/**
 * @typedef {{lineCap: string,
 *            lineDash: Array.<number>,
 *            lineJoin: string,
 *            lineWidth: number,
 *            miterLimit: number,
 *            strokeStyle: ol.ColorLike}}
 */
ol.CanvasStrokeState;
 
 
/**
 * @typedef {{font: string,
 *            textAlign: string,
 *            textBaseline: string}}
 */
ol.CanvasTextState;
 
 
/**
 * @typedef {function((ol.Coordinate|undefined)): (ol.Coordinate|undefined)}
 */
ol.CenterConstraintType;
 
 
/**
 * @typedef {{strokeStyle: (ol.ColorLike|undefined), strokeWidth: number,
 *   size: number, lineDash: Array.<number>}}
 */
ol.CircleRenderOptions;
 
 
/**
 * A color represented as a short array [red, green, blue, alpha].
 * red, green, and blue should be integers in the range 0..255 inclusive.
 * alpha should be a float in the range 0..1 inclusive. If no alpha value is
 * given then `1` will be used.
 * @typedef {Array.<number>}
 */
ol.Color;
 
 
/**
 * A type accepted by CanvasRenderingContext2D.fillStyle
 * or CanvasRenderingContext2D.strokeStyle.
 * Represents a color, pattern, or gradient. The origin for patterns and
 * gradients as fill style is the top-left corner of the extent of the geometry
 * being filled.
 *
 * @typedef {string|CanvasPattern|CanvasGradient}
 */
ol.ColorLike;
 
 
/**
 * An array of numbers representing an xy coordinate. Example: `[16, 48]`.
 * @typedef {Array.<number>}
 */
ol.Coordinate;
 
 
/**
 * A function that takes a {@link ol.Coordinate} and transforms it into a
 * `{string}`.
 *
 * @typedef {function((ol.Coordinate|undefined)): string}
 */
ol.CoordinateFormatType;
 
 
/**
 * A function that takes a {@link ol.MapBrowserEvent} and two
 * {@link ol.Pixel}s and returns a `{boolean}`. If the condition is met,
 * true should be returned.
 * @typedef {function(ol.MapBrowserEvent, ol.Pixel, ol.Pixel):boolean}
 */
ol.DragBoxEndConditionType;
 
 
/**
 * Function that takes coordinates and an optional existing geometry as
 * arguments, and returns a geometry. The optional existing geometry is the
 * geometry that is returned when the function is called without a second
 * argument.
 * @typedef {function(!(ol.Coordinate|Array.<ol.Coordinate>|
 *     Array.<Array.<ol.Coordinate>>), ol.geom.SimpleGeometry=):
 *     ol.geom.SimpleGeometry}
 */
ol.DrawGeometryFunctionType;
 
 
/**
 * A function that takes an {@link ol.MapBrowserEvent} and returns a
 * `{boolean}`. If the condition is met, true should be returned.
 *
 * @typedef {function(ol.MapBrowserEvent): boolean}
 */
ol.EventsConditionType;
 
 
/**
 * Key to use with {@link ol.Observable#unByKey}.
 *
 * @typedef {{bindTo: (Object|undefined),
 *     boundListener: (ol.EventsListenerFunctionType|undefined),
 *     callOnce: boolean,
 *     deleteIndex: (number|undefined),
 *     listener: ol.EventsListenerFunctionType,
 *     target: (EventTarget|ol.events.EventTarget),
 *     type: string}}
 */
ol.EventsKey;
 
 
/**
 * Listener function. This function is called with an event object as argument.
 * When the function returns `false`, event propagation will stop.
 *
 * @typedef {function(ol.events.Event)|function(ol.events.Event): boolean}
 */
ol.EventsListenerFunctionType;
 
 
/**
 * @typedef {EventTarget|ol.events.EventTarget}
 */
ol.EventTargetLike;
 
 
/**
 * An array of numbers representing an extent: `[minx, miny, maxx, maxy]`.
 * @typedef {Array.<number>}
 */
ol.Extent;
 
 
/**
 * {@link ol.source.Vector} sources use a function of this type to load
 * features.
 *
 * This function takes an {@link ol.Extent} representing the area to be loaded,
 * a `{number}` representing the resolution (map units per pixel) and an
 * {@link ol.proj.Projection} for the projection  as arguments. `this` within
 * the function is bound to the {@link ol.source.Vector} it's called from.
 *
 * The function is responsible for loading the features and adding them to the
 * source.
 * @typedef {function(this:ol.source.Vector, ol.Extent, number,
 *                    ol.proj.Projection)}
 */
ol.FeatureLoader;
 
 
/**
 * A function that returns an array of {@link ol.style.Style styles} given a
 * resolution. The `this` keyword inside the function references the
 * {@link ol.Feature} to be styled.
 *
 * @typedef {function(this: ol.Feature, number):
 *     (ol.style.Style|Array.<ol.style.Style>)}
 */
ol.FeatureStyleFunction;
 
 
/**
 * {@link ol.source.Vector} sources use a function of this type to get the url
 * to load features from.
 *
 * This function takes an {@link ol.Extent} representing the area to be loaded,
 * a `{number}` representing the resolution (map units per pixel) and an
 * {@link ol.proj.Projection} for the projection  as arguments and returns a
 * `{string}` representing the URL.
 * @typedef {function(ol.Extent, number, ol.proj.Projection) : string}
 */
ol.FeatureUrlFunction;
 
 
/**
 * A function that is called to trigger asynchronous canvas drawing.  It is
 * called with a "done" callback that should be called when drawing is done.
 * If any error occurs during drawing, the "done" callback should be called with
 * that error.
 *
 * @typedef {function(function(Error))}
 */
ol.ImageCanvasLoader;
 
 
/**
 * A function that takes an {@link ol.Image} for the image and a `{string}` for
 * the src as arguments. It is supposed to make it so the underlying image
 * {@link ol.Image#getImage} is assigned the content specified by the src. If
 * not specified, the default is
 *
 *     function(image, src) {
 *       image.getImage().src = src;
 *     }
 *
 * Providing a custom `imageLoadFunction` can be useful to load images with
 * post requests or - in general - through XHR requests, where the src of the
 * image element would be set to a data URI when the content is loaded.
 *
 * @typedef {function(ol.Image, string)}
 */
ol.ImageLoadFunctionType;
 
 
/**
 * @typedef {{x: number, xunits: (ol.style.IconAnchorUnits|undefined),
 *            y: number, yunits: (ol.style.IconAnchorUnits|undefined)}}
 */
ol.KMLVec2_;
 
 
/**
 * @typedef {{flatCoordinates: Array.<number>,
 *            whens: Array.<number>}}
 */
ol.KMLGxTrackObject_;
 
 
/**
 * @typedef {{layer: ol.layer.Layer,
 *            opacity: number,
 *            sourceState: ol.source.State,
 *            visible: boolean,
 *            managed: boolean,
 *            extent: (ol.Extent|undefined),
 *            zIndex: number,
 *            maxResolution: number,
 *            minResolution: number}}
 */
ol.LayerState;
 
 
/**
 * @typedef {{hasZ: (boolean|undefined), hasM: (boolean|undefined)}}
 */
ol.LayoutOptions;
 
 
/**
 * @typedef {{prev: (ol.LinkedListItem|undefined),
 *            next: (ol.LinkedListItem|undefined),
 *            data: ?}}
 */
ol.LinkedListItem;
 
 
/**
 * A function that takes an {@link ol.Extent} and a resolution as arguments, and
 * returns an array of {@link ol.Extent} with the extents to load. Usually this
 * is one of the standard {@link ol.loadingstrategy} strategies.
 *
 * @typedef {function(ol.Extent, number): Array.<ol.Extent>}
 */
ol.LoadingStrategy;
 
 
/**
 * @typedef {{key_: string,
 *            newer: Object,
 *            older: Object,
 *            value_: *}}
 */
ol.LRUCacheEntry;
 
 
/**
 * @typedef {{controls: ol.Collection.<ol.control.Control>,
 *            interactions: ol.Collection.<ol.interaction.Interaction>,
 *            keyboardEventTarget: (Element|Document),
 *            logos: (Object.<string, (string|Element)>),
 *            overlays: ol.Collection.<ol.Overlay>,
 *            rendererConstructor:
 *                function(new: ol.renderer.Map, Element, ol.Map),
 *            values: Object.<string, *>}}
 */
ol.MapOptionsInternal;
 
 
/**
 * An array representing an affine 2d transformation for use with
 * {@link ol.transform} functions. The array has 6 elements.
 * @typedef {!Array.<number>}
 */
ol.Transform;
 
 
/**
 * @typedef {{depth: (Array.<number>|undefined),
 *            feature: ol.Feature,
 *            geometry: ol.geom.SimpleGeometry,
 *            index: (number),
 *            segment: Array.<ol.Extent>,
 *            featureSegments: (Array.<ol.ModifySegmentDataType>|undefined)}}
 */
ol.ModifySegmentDataType;
 
 
/**
 * An array with two elements, representing a pixel. The first element is the
 * x-coordinate, the second the y-coordinate of the pixel.
 * @typedef {Array.<number>}
 */
ol.Pixel;
 
 
/**
 * @typedef {function(ol.Map, ?olx.FrameState): boolean}
 */
ol.PostRenderFunction;
 
 
/**
 * Function to perform manipulations before rendering. This function is called
 * with the {@link ol.Map} as first and an optional {@link olx.FrameState} as
 * second argument. Return `true` to keep this function for the next frame,
 * `false` to remove it.
 * @typedef {function(ol.Map, ?olx.FrameState): boolean}
 */
ol.PreRenderFunction;
 
 
/**
 * A projection as {@link ol.proj.Projection}, SRS identifier string or
 * undefined.
 * @typedef {ol.proj.Projection|string|undefined} ol.ProjectionLike
 */
ol.ProjectionLike;
 
 
/**
 * A function that takes an array of input data, performs some operation, and
 * returns an array of ouput data.
 * For `pixel` type operations, the function will be called with an array of
 * pixels, where each pixel is an array of four numbers (`[r, g, b, a]`) in the
 * range of 0 - 255. It should return a single pixel array.
 * For `'image'` type operations, functions will be called with an array of
 * {@link ImageData https://developer.mozilla.org/en-US/docs/Web/API/ImageData}
 * and should return a single {@link ImageData
 * https://developer.mozilla.org/en-US/docs/Web/API/ImageData}.  The operations
 * are called with a second "data" argument, which can be used for storage.  The
 * data object is accessible from raster events, where it can be initialized in
 * "beforeoperations" and accessed again in "afteroperations".
 *
 * @typedef {function((Array.<Array.<number>>|Array.<ImageData>), Object):
 *     (Array.<number>|ImageData)}
 */
ol.RasterOperation;
 
 
/**
 * @typedef {{
 *   strokeStyle: (ol.ColorLike|undefined),
 *   strokeWidth: number,
 *   size: number,
 *   lineCap: string,
 *   lineDash: Array.<number>,
 *   lineJoin: string,
 *   miterLimit: number
 * }}
 */
ol.RegularShapeRenderOptions;
 
 
/**
 * A function to be used when sorting features before rendering.
 * It takes two instances of {@link ol.Feature} and returns a `{number}`.
 *
 * @typedef {function(ol.Feature, ol.Feature):number}
 */
ol.RenderOrderFunction;
 
 
/**
 * @typedef {function(ol.Extent, number, number) : ol.ImageBase}
 */
ol.ReprojImageFunctionType;
 
 
/**
 * @typedef {function(number, number, number, number) : ol.Tile}
 */
ol.ReprojTileFunctionType;
 
 
/**
 * Single triangle; consists of 3 source points and 3 target points.
 *
 * @typedef {{source: Array.<ol.Coordinate>,
 *            target: Array.<ol.Coordinate>}}
 */
ol.ReprojTriangle;
 
 
/**
 * @typedef {function((number|undefined), number, number): (number|undefined)}
 */
ol.ResolutionConstraintType;
 
 
/**
 * @typedef {function((number|undefined), number): (number|undefined)}
 */
ol.RotationConstraintType;
 
 
/**
 * A function that takes an {@link ol.Feature} or {@link ol.render.Feature} and
 * an {@link ol.layer.Layer} and returns `true` if the feature may be selected
 * or `false` otherwise.
 * @typedef {function((ol.Feature|ol.render.Feature), ol.layer.Layer):
 *     boolean}
 */
ol.SelectFilterFunction;
 
 
/**
 * An array of numbers representing a size: `[width, height]`.
 * @typedef {Array.<number>}
 */
ol.Size;
 
 
/**
 * @typedef {{
 *     snapped: {boolean},
 *     vertex: (ol.Coordinate|null),
 *     vertexPixel: (ol.Pixel|null)
 * }}
 */
ol.SnapResultType;
 
 
/**
 * @typedef {{
 *     feature: ol.Feature,
 *     segment: Array.<ol.Coordinate>
 * }}
 */
ol.SnapSegmentDataType;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *            extent: (null|ol.Extent|undefined),
 *            logo: (string|olx.LogoOptions|undefined),
 *            projection: ol.ProjectionLike,
 *            resolutions: (Array.<number>|undefined),
 *            state: (ol.source.State|undefined)}}
 */
ol.SourceImageOptions;
 
 
/**
 * @typedef {{revision: number,
 *            resolution: number,
 *            extent: ol.Extent}}
 */
ol.SourceRasterRenderedState;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *            logo: (string|olx.LogoOptions|undefined),
 *            projection: ol.ProjectionLike,
 *            state: (ol.source.State|undefined),
 *            wrapX: (boolean|undefined)}}
 */
ol.SourceSourceOptions;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *            cacheSize: (number|undefined),
 *            extent: (ol.Extent|undefined),
 *            logo: (string|olx.LogoOptions|undefined),
 *            opaque: (boolean|undefined),
 *            tilePixelRatio: (number|undefined),
 *            projection: ol.ProjectionLike,
 *            state: (ol.source.State|undefined),
 *            tileGrid: (ol.tilegrid.TileGrid|undefined),
 *            wrapX: (boolean|undefined)}}
 */
ol.SourceTileOptions;
 
 
/**
 * @typedef {{attributions: (ol.AttributionLike|undefined),
 *            cacheSize: (number|undefined),
 *            extent: (ol.Extent|undefined),
 *            logo: (string|olx.LogoOptions|undefined),
 *            opaque: (boolean|undefined),
 *            projection: ol.ProjectionLike,
 *            state: (ol.source.State|undefined),
 *            tileGrid: (ol.tilegrid.TileGrid|undefined),
 *            tileLoadFunction: ol.TileLoadFunctionType,
 *            tilePixelRatio: (number|undefined),
 *            tileUrlFunction: (ol.TileUrlFunctionType|undefined),
 *            url: (string|undefined),
 *            urls: (Array.<string>|undefined),
 *            wrapX: (boolean|undefined)}}
 */
ol.SourceUrlTileOptions;
 
 
/**
 * A function that takes an {@link ol.Feature} and a `{number}` representing
 * the view's resolution. The function should return a {@link ol.style.Style}
 * or an array of them. This way e.g. a vector layer can be styled.
 *
 * @typedef {function((ol.Feature|ol.render.Feature), number):
 *     (ol.style.Style|Array.<ol.style.Style>)}
 */
ol.StyleFunction;
 
 
/**
 * A function that takes an {@link ol.Feature} as argument and returns an
 * {@link ol.geom.Geometry} that will be rendered and styled for the feature.
 *
 * @typedef {function((ol.Feature|ol.render.Feature)):
 *     (ol.geom.Geometry|ol.render.Feature|undefined)}
 */
ol.StyleGeometryFunction;
 
 
/**
 * @typedef {{opacity: number,
 *            rotateWithView: boolean,
 *            rotation: number,
 *            scale: number,
 *            snapToPixel: boolean}}
 */
ol.StyleImageOptions;
 
 
/**
 * An array of three numbers representing the location of a tile in a tile
 * grid. The order is `z`, `x`, and `y`. `z` is the zoom level.
 * @typedef {Array.<number>} ol.TileCoord
 */
ol.TileCoord;
 
 
/**
 * A function that takes an {@link ol.Tile} for the tile and a `{string}` for
 * the url as arguments.
 *
 * @typedef {function(ol.Tile, string)}
 */
ol.TileLoadFunctionType;
 
 
/**
 * @typedef {function(ol.Tile, string, ol.Coordinate, number): number}
 */
ol.TilePriorityFunction;
 
 
/**
 * @typedef {{
 *     dirty: boolean,
 *     renderedRenderOrder: (null|ol.RenderOrderFunction),
 *     renderedTileRevision: number,
 *     renderedRevision: number,
 *     replayGroup: ol.render.ReplayGroup}}
 */
ol.TileReplayState;
 
 
/**
 * {@link ol.source.Tile} sources use a function of this type to get the url
 * that provides a tile for a given tile coordinate.
 *
 * This function takes an {@link ol.TileCoord} for the tile coordinate, a
 * `{number}` representing the pixel ratio and an {@link ol.proj.Projection} for
 * the projection  as arguments and returns a `{string}` representing the tile
 * URL, or undefined if no tile should be requested for the passed tile
 * coordinate.
 *
 * @typedef {function(ol.TileCoord, number,
 *           ol.proj.Projection): (string|undefined)}
 */
ol.TileUrlFunctionType;
 
 
/**
 * A transform function accepts an array of input coordinate values, an optional
 * output array, and an optional dimension (default should be 2).  The function
 * transforms the input coordinate values, populates the output array, and
 * returns the output array.
 *
 * @typedef {function(Array.<number>, Array.<number>=, number=): Array.<number>}
 */
ol.TransformFunction;
 
 
/**
 * An animation configuration
 *
 * @typedef {{
 *   sourceCenter: (ol.Coordinate|undefined),
 *   targetCenter: (ol.Coordinate|undefined),
 *   sourceResolution: (number|undefined),
 *   targetResolution: (number|undefined),
 *   sourceRotation: (number|undefined),
 *   targetRotation: (number|undefined),
 *   anchor: (ol.Coordinate|undefined),
 *   start: number,
 *   duration: number,
 *   complete: boolean,
 *   easing: function(number):number,
 *   callback: (function(boolean)|undefined)
 *  }}
 */
ol.ViewAnimation;
 
 
/**
 * @typedef {{buf: ol.webgl.Buffer,
 *            buffer: WebGLBuffer}}
 */
ol.WebglBufferCacheEntry;
 
 
/**
 * @typedef {{p0: ol.WebglPolygonVertex,
 *            p1: ol.WebglPolygonVertex}}
 */
ol.WebglPolygonSegment;
 
/**
 * @typedef {{x: number,
 *            y: number,
 *            i: number,
 *            reflex: (boolean|undefined)}}
 */
ol.WebglPolygonVertex;
 
 
/**
 * @typedef {{magFilter: number, minFilter: number, texture: WebGLTexture}}
 */
ol.WebglTextureCacheEntry;
 
 
/**
 * Number of features; bounds/extent.
 * @typedef {{numberOfFeatures: number,
 *            bounds: ol.Extent}}
 */
ol.WFSFeatureCollectionMetadata;
 
 
/**
 * Total deleted; total inserted; total updated; array of insert ids.
 * @typedef {{totalDeleted: number,
 *            totalInserted: number,
 *            totalUpdated: number,
 *            insertIds: Array.<string>}}
 */
ol.WFSTransactionResponse;
 
 
/**
 * @typedef {{type: number, value: (number|string|undefined), position: number}}
 */
ol.WKTToken;
 
 
/**
 * When using {@link ol.xml.makeChildAppender} or
 * {@link ol.xml.makeSimpleNodeFactory}, the top `objectStack` item needs to
 * have this structure.
 * @typedef {{node:Node}}
 */
ol.XmlNodeStackItem;
 
 
/**
 * @typedef {function(Node, Array.<*>)}
 */
ol.XmlParser;
 
 
/**
 * @typedef {function(Node, *, Array.<*>)}
 */
ol.XmlSerializer;
 
 
/**
 * @typedef {{minX: number, minY: number, maxX: number, maxY: number,
 *            value: (Object|undefined)}}
 */
ol.RBushEntry;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/uri.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/uri.js

Statements: 10% (1 / 10)      Branches: 0% (0 / 6)      Functions: 0% (0 / 2)      Lines: 10% (1 / 10)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 282                                                      
goog.provide('ol.uri');
 
 
/**
 * Appends query parameters to a URI.
 *
 * @param {string} uri The original URI, which may already have query data.
 * @param {!Object} params An object where keys are URI-encoded parameter keys,
 *     and the values are arbitrary types or arrays.
 * @return {string} The new URI.
 */
ol.uri.appendParams = function(uri, params) {
  var keyParams = [];
  // Skip any null or undefined parameter values
  Object.keys(params).forEach(function(k) {
    if (params[k] !== null && params[k] !== undefined) {
      keyParams.push(k + '=' + encodeURIComponent(params[k]));
    }
  });
  var qs = keyParams.join('&');
  // remove any trailing ? or &
  uri = uri.replace(/[?&]$/, '');
  // append ? or & depending on whether uri has existing parameters
  uri = uri.indexOf('?') === -1 ? uri + '?' : uri + '&';
  return uri + qs;
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/vectortile.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/vectortile.js

Statements: 1.79% (1 / 56)      Branches: 0% (0 / 6)      Functions: 0% (0 / 16)      Lines: 1.79% (1 / 56)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 2262                                                                                                                                                                                                                                                                                                                                                                                                                                                                  
goog.provide('ol.VectorTile');
 
goog.require('ol');
goog.require('ol.Tile');
goog.require('ol.TileState');
goog.require('ol.dom');
goog.require('ol.featureloader');
 
 
/**
 * @constructor
 * @extends {ol.Tile}
 * @param {ol.TileCoord} tileCoord Tile coordinate.
 * @param {ol.TileState} state State.
 * @param {string} src Data source url.
 * @param {ol.format.Feature} format Feature format.
 * @param {ol.TileLoadFunctionType} tileLoadFunction Tile load function.
 */
ol.VectorTile = function(tileCoord, state, src, format, tileLoadFunction) {
 
  ol.Tile.call(this, tileCoord, state);
 
  /**
   * @private
   * @type {CanvasRenderingContext2D}
   */
  this.context_ = null;
 
  /**
   * @private
   * @type {ol.format.Feature}
   */
  this.format_ = format;
 
  /**
   * @private
   * @type {Array.<ol.Feature>}
   */
  this.features_ = null;
 
  /**
   * @private
   * @type {ol.FeatureLoader}
   */
  this.loader_;
 
  /**
   * Data projection
   * @private
   * @type {ol.proj.Projection}
   */
  this.projection_;
 
  /**
   * @private
   * @type {ol.TileReplayState}
   */
  this.replayState_ = {
    dirty: false,
    renderedRenderOrder: null,
    renderedRevision: -1,
    renderedTileRevision: -1,
    replayGroup: null
  };
 
  /**
   * @private
   * @type {ol.TileLoadFunctionType}
   */
  this.tileLoadFunction_ = tileLoadFunction;
 
  /**
   * @private
   * @type {string}
   */
  this.url_ = src;
 
};
ol.inherits(ol.VectorTile, ol.Tile);
 
 
/**
 * @return {CanvasRenderingContext2D} The rendering context.
 */
ol.VectorTile.prototype.getContext = function() {
  if (!this.context_) {
    this.context_ = ol.dom.createCanvasContext2D();
  }
  return this.context_;
};
 
 
/**
 * @override
 */
ol.VectorTile.prototype.getImage = function() {
  return this.replayState_.renderedTileRevision == -1 ?
      null : this.context_.canvas;
};
 
 
/**
 * Get the feature format assigned for reading this tile's features.
 * @return {ol.format.Feature} Feature format.
 * @api
 */
ol.VectorTile.prototype.getFormat = function() {
  return this.format_;
};
 
 
/**
 * @return {Array.<ol.Feature>} Features.
 */
ol.VectorTile.prototype.getFeatures = function() {
  return this.features_;
};
 
 
/**
 * @return {ol.TileReplayState} The replay state.
 */
ol.VectorTile.prototype.getReplayState = function() {
  return this.replayState_;
};
 
 
/**
 * @inheritDoc
 */
ol.VectorTile.prototype.getKey = function() {
  return this.url_;
};
 
 
/**
 * @return {ol.proj.Projection} Feature projection.
 */
ol.VectorTile.prototype.getProjection = function() {
  return this.projection_;
};
 
 
/**
 * @inheritDoc
 */
ol.VectorTile.prototype.load = function() {
  if (this.state == ol.TileState.IDLE) {
    this.setState(ol.TileState.LOADING);
    this.tileLoadFunction_(this, this.url_);
    this.loader_(null, NaN, null);
  }
};
 
 
/**
 * Handler for successful tile load.
 * @param {Array.<ol.Feature>} features The loaded features.
 * @param {ol.proj.Projection} dataProjection Data projection.
 */
ol.VectorTile.prototype.onLoad_ = function(features, dataProjection) {
  this.setProjection(dataProjection);
  this.setFeatures(features);
};
 
 
/**
 * Handler for tile load errors.
 */
ol.VectorTile.prototype.onError_ = function() {
  this.setState(ol.TileState.ERROR);
};
 
 
/**
 * @param {Array.<ol.Feature>} features Features.
 * @api
 */
ol.VectorTile.prototype.setFeatures = function(features) {
  this.features_ = features;
  this.setState(ol.TileState.LOADED);
};
 
 
/**
 * Set the projection of the features that were added with {@link #setFeatures}.
 * @param {ol.proj.Projection} projection Feature projection.
 * @api
 */
ol.VectorTile.prototype.setProjection = function(projection) {
  this.projection_ = projection;
};
 
 
/**
 * @param {ol.TileState} tileState Tile state.
 */
ol.VectorTile.prototype.setState = function(tileState) {
  this.state = tileState;
  this.changed();
};
 
 
/**
 * Set the feature loader for reading this tile's features.
 * @param {ol.FeatureLoader} loader Feature loader.
 * @api
 */
ol.VectorTile.prototype.setLoader = function(loader) {
  this.loader_ = loader;
};
 
 
/**
 * Sets the loader for a tile.
 * @param {ol.VectorTile} tile Vector tile.
 * @param {string} url URL.
 */
ol.VectorTile.defaultLoadFunction = function(tile, url) {
  var loader = ol.featureloader.loadFeaturesXhr(
      url, tile.getFormat(), tile.onLoad_.bind(tile), tile.onError_.bind(tile));
 
  tile.setLoader(loader);
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/view.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/view.js

Statements: 0.24% (1 / 423)      Branches: 0% (0 / 172)      Functions: 0% (0 / 46)      Lines: 0.24% (1 / 423)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 11262                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          
goog.provide('ol.View');
 
goog.require('ol');
goog.require('ol.CenterConstraint');
goog.require('ol.Constraints');
goog.require('ol.Object');
goog.require('ol.ResolutionConstraint');
goog.require('ol.RotationConstraint');
goog.require('ol.ViewHint');
goog.require('ol.ViewProperty');
goog.require('ol.array');
goog.require('ol.asserts');
goog.require('ol.coordinate');
goog.require('ol.easing');
goog.require('ol.extent');
goog.require('ol.geom.GeometryType');
goog.require('ol.geom.Polygon');
goog.require('ol.geom.SimpleGeometry');
goog.require('ol.obj');
goog.require('ol.proj');
goog.require('ol.proj.Units');
 
 
/**
 * @classdesc
 * An ol.View object represents a simple 2D view of the map.
 *
 * This is the object to act upon to change the center, resolution,
 * and rotation of the map.
 *
 * ### The view states
 *
 * An `ol.View` is determined by three states: `center`, `resolution`,
 * and `rotation`. Each state has a corresponding getter and setter, e.g.
 * `getCenter` and `setCenter` for the `center` state.
 *
 * An `ol.View` has a `projection`. The projection determines the
 * coordinate system of the center, and its units determine the units of the
 * resolution (projection units per pixel). The default projection is
 * Spherical Mercator (EPSG:3857).
 *
 * ### The constraints
 *
 * `setCenter`, `setResolution` and `setRotation` can be used to change the
 * states of the view. Any value can be passed to the setters. And the value
 * that is passed to a setter will effectively be the value set in the view,
 * and returned by the corresponding getter.
 *
 * But an `ol.View` object also has a *resolution constraint*, a
 * *rotation constraint* and a *center constraint*.
 *
 * As said above, no constraints are applied when the setters are used to set
 * new states for the view. Applying constraints is done explicitly through
 * the use of the `constrain*` functions (`constrainResolution` and
 * `constrainRotation` and `constrainCenter`).
 *
 * The main users of the constraints are the interactions and the
 * controls. For example, double-clicking on the map changes the view to
 * the "next" resolution. And releasing the fingers after pinch-zooming
 * snaps to the closest resolution (with an animation).
 *
 * The *resolution constraint* snaps to specific resolutions. It is
 * determined by the following options: `resolutions`, `maxResolution`,
 * `maxZoom`, and `zoomFactor`. If `resolutions` is set, the other three
 * options are ignored. See documentation for each option for more
 * information.
 *
 * The *rotation constraint* snaps to specific angles. It is determined
 * by the following options: `enableRotation` and `constrainRotation`.
 * By default the rotation value is snapped to zero when approaching the
 * horizontal.
 *
 * The *center constraint* is determined by the `extent` option. By
 * default the center is not constrained at all.
 *
 * @constructor
 * @extends {ol.Object}
 * @param {olx.ViewOptions=} opt_options View options.
 * @api
 */
ol.View = function(opt_options) {
  ol.Object.call(this);
 
  var options = ol.obj.assign({}, opt_options);
 
  /**
   * @private
   * @type {Array.<number>}
   */
  this.hints_ = [0, 0];
 
  /**
   * @private
   * @type {Array.<Array.<ol.ViewAnimation>>}
   */
  this.animations_ = [];
 
  /**
   * @private
   * @type {number|undefined}
   */
  this.updateAnimationKey_;
 
  this.updateAnimations_ = this.updateAnimations_.bind(this);
 
  /**
   * @private
   * @const
   * @type {ol.proj.Projection}
   */
  this.projection_ = ol.proj.createProjection(options.projection, 'EPSG:3857');
 
  this.applyOptions_(options);
};
ol.inherits(ol.View, ol.Object);
 
 
/**
 * Set up the view with the given options.
 * @param {olx.ViewOptions} options View options.
 */
ol.View.prototype.applyOptions_ = function(options) {
 
  /**
   * @type {Object.<string, *>}
   */
  var properties = {};
  properties[ol.ViewProperty.CENTER] = options.center !== undefined ?
      options.center : null;
 
  var resolutionConstraintInfo = ol.View.createResolutionConstraint_(
      options);
 
  /**
   * @private
   * @type {number}
   */
  this.maxResolution_ = resolutionConstraintInfo.maxResolution;
 
  /**
   * @private
   * @type {number}
   */
  this.minResolution_ = resolutionConstraintInfo.minResolution;
 
  /**
   * @private
   * @type {number}
   */
  this.zoomFactor_ = resolutionConstraintInfo.zoomFactor;
 
  /**
   * @private
   * @type {Array.<number>|undefined}
   */
  this.resolutions_ = options.resolutions;
 
  /**
   * @private
   * @type {number}
   */
  this.minZoom_ = resolutionConstraintInfo.minZoom;
 
  var centerConstraint = ol.View.createCenterConstraint_(options);
  var resolutionConstraint = resolutionConstraintInfo.constraint;
  var rotationConstraint = ol.View.createRotationConstraint_(options);
 
  /**
   * @private
   * @type {ol.Constraints}
   */
  this.constraints_ = new ol.Constraints(
      centerConstraint, resolutionConstraint, rotationConstraint);
 
  if (options.resolution !== undefined) {
    properties[ol.ViewProperty.RESOLUTION] = options.resolution;
  } else if (options.zoom !== undefined) {
    properties[ol.ViewProperty.RESOLUTION] = this.constrainResolution(
        this.maxResolution_, options.zoom - this.minZoom_);
  }
  properties[ol.ViewProperty.ROTATION] =
      options.rotation !== undefined ? options.rotation : 0;
  this.setProperties(properties);
 
  /**
   * @private
   * @type {olx.ViewOptions}
   */
  this.options_ = options;
 
};
 
/**
 * Get an updated version of the view options used to construct the view.  The
 * current resolution (or zoom), center, and rotation are applied to any stored
 * options.  The provided options can be uesd to apply new min/max zoom or
 * resolution limits.
 * @param {olx.ViewOptions} newOptions New options to be applied.
 * @return {olx.ViewOptions} New options updated with the current view state.
 */
ol.View.prototype.getUpdatedOptions_ = function(newOptions) {
  var options = ol.obj.assign({}, this.options_);
 
  // preserve resolution (or zoom)
  if (options.resolution !== undefined) {
    options.resolution = this.getResolution();
  } else {
    options.zoom = this.getZoom();
  }
 
  // preserve center
  options.center = this.getCenter();
 
  // preserve rotation
  options.rotation = this.getRotation();
 
  return ol.obj.assign({}, options, newOptions);
};
 
 
/**
 * Animate the view.  The view's center, zoom (or resolution), and rotation
 * can be animated for smooth transitions between view states.  For example,
 * to animate the view to a new zoom level:
 *
 *     view.animate({zoom: view.getZoom() + 1});
 *
 * By default, the animation lasts one second and uses in-and-out easing.  You
 * can customize this behavior by including `duration` (in milliseconds) and
 * `easing` options (see {@link ol.easing}).
 *
 * To chain together multiple animations, call the method with multiple
 * animation objects.  For example, to first zoom and then pan:
 *
 *     view.animate({zoom: 10}, {center: [0, 0]});
 *
 * If you provide a function as the last argument to the animate method, it
 * will get called at the end of an animation series.  The callback will be
 * called with `true` if the animation series completed on its own or `false`
 * if it was cancelled.
 *
 * Animations are cancelled by user interactions (e.g. dragging the map) or by
 * calling `view.setCenter()`, `view.setResolution()`, or `view.setRotation()`
 * (or another method that calls one of these).
 *
 * @param {...(olx.AnimationOptions|function(boolean))} var_args Animation
 *     options.  Multiple animations can be run in series by passing multiple
 *     options objects.  To run multiple animations in parallel, call the method
 *     multiple times.  An optional callback can be provided as a final
 *     argument.  The callback will be called with a boolean indicating whether
 *     the animation completed without being cancelled.
 * @api
 */
ol.View.prototype.animate = function(var_args) {
  var start = Date.now();
  var center = this.getCenter().slice();
  var resolution = this.getResolution();
  var rotation = this.getRotation();
  var animationCount = arguments.length;
  var callback;
  if (animationCount > 1 && typeof arguments[animationCount - 1] === 'function') {
    callback = arguments[animationCount - 1];
    --animationCount;
  }
  var series = [];
  for (var i = 0; i < animationCount; ++i) {
    var options = /** @type {olx.AnimationOptions} */ (arguments[i]);
 
    var animation = /** @type {ol.ViewAnimation} */ ({
      start: start,
      complete: false,
      anchor: options.anchor,
      duration: options.duration !== undefined ? options.duration : 1000,
      easing: options.easing || ol.easing.inAndOut
    });
 
    if (options.center) {
      animation.sourceCenter = center;
      animation.targetCenter = options.center;
      center = animation.targetCenter;
    }
 
    if (options.zoom !== undefined) {
      animation.sourceResolution = resolution;
      animation.targetResolution = this.constrainResolution(
            this.maxResolution_, options.zoom - this.minZoom_, 0);
      resolution = animation.targetResolution;
    } else if (options.resolution) {
      animation.sourceResolution = resolution;
      animation.targetResolution = options.resolution;
      resolution = animation.targetResolution;
    }
 
    if (options.rotation !== undefined) {
      animation.sourceRotation = rotation;
      animation.targetRotation = options.rotation;
      rotation = animation.targetRotation;
    }
 
    animation.callback = callback;
    start += animation.duration;
    series.push(animation);
  }
  this.animations_.push(series);
  this.setHint(ol.ViewHint.ANIMATING, 1);
  this.updateAnimations_();
};
 
 
/**
 * Determine if the view is being animated.
 * @return {boolean} The view is being animated.
 * @api
 */
ol.View.prototype.getAnimating = function() {
  return this.getHints()[ol.ViewHint.ANIMATING] > 0;
};
 
 
/**
 * Cancel any ongoing animations.
 * @api
 */
ol.View.prototype.cancelAnimations = function() {
  this.setHint(ol.ViewHint.ANIMATING, -this.getHints()[ol.ViewHint.ANIMATING]);
  for (var i = 0, ii = this.animations_.length; i < ii; ++i) {
    var series = this.animations_[i];
    if (series[0].callback) {
      series[0].callback(false);
    }
  }
  this.animations_.length = 0;
};
 
/**
 * Update all animations.
 */
ol.View.prototype.updateAnimations_ = function() {
  if (this.updateAnimationKey_ !== undefined) {
    cancelAnimationFrame(this.updateAnimationKey_);
    this.updateAnimationKey_ = undefined;
  }
  if (!this.getAnimating()) {
    return;
  }
  var now = Date.now();
  var more = false;
  for (var i = this.animations_.length - 1; i >= 0; --i) {
    var series = this.animations_[i];
    var seriesComplete = true;
    for (var j = 0, jj = series.length; j < jj; ++j) {
      var animation = series[j];
      if (animation.complete) {
        continue;
      }
      var elapsed = now - animation.start;
      var fraction = animation.duration > 0 ? elapsed / animation.duration : 1;
      if (fraction >= 1) {
        animation.complete = true;
        fraction = 1;
      } else {
        seriesComplete = false;
      }
      var progress = animation.easing(fraction);
      if (animation.sourceCenter) {
        var x0 = animation.sourceCenter[0];
        var y0 = animation.sourceCenter[1];
        var x1 = animation.targetCenter[0];
        var y1 = animation.targetCenter[1];
        var x = x0 + progress * (x1 - x0);
        var y = y0 + progress * (y1 - y0);
        this.set(ol.ViewProperty.CENTER, [x, y]);
      }
      if (animation.sourceResolution && animation.targetResolution) {
        var resolution = progress === 1 ?
            animation.targetResolution :
            animation.sourceResolution + progress * (animation.targetResolution - animation.sourceResolution);
        if (animation.anchor) {
          this.set(ol.ViewProperty.CENTER,
              this.calculateCenterZoom(resolution, animation.anchor));
        }
        this.set(ol.ViewProperty.RESOLUTION, resolution);
      }
      if (animation.sourceRotation !== undefined && animation.targetRotation !== undefined) {
        var rotation = progress === 1 ?
            animation.targetRotation :
            animation.sourceRotation + progress * (animation.targetRotation - animation.sourceRotation);
        if (animation.anchor) {
          this.set(ol.ViewProperty.CENTER,
              this.calculateCenterRotate(rotation, animation.anchor));
        }
        this.set(ol.ViewProperty.ROTATION, rotation);
      }
      more = true;
      if (!animation.complete) {
        break;
      }
    }
    if (seriesComplete) {
      this.animations_[i] = null;
      this.setHint(ol.ViewHint.ANIMATING, -1);
      var callback = series[0].callback;
      if (callback) {
        callback(true);
      }
    }
  }
  // prune completed series
  this.animations_ = this.animations_.filter(Boolean);
  if (more && this.updateAnimationKey_ === undefined) {
    this.updateAnimationKey_ = requestAnimationFrame(this.updateAnimations_);
  }
};
 
/**
 * @param {number} rotation Target rotation.
 * @param {ol.Coordinate} anchor Rotation anchor.
 * @return {ol.Coordinate|undefined} Center for rotation and anchor.
 */
ol.View.prototype.calculateCenterRotate = function(rotation, anchor) {
  var center;
  var currentCenter = this.getCenter();
  if (currentCenter !== undefined) {
    center = [currentCenter[0] - anchor[0], currentCenter[1] - anchor[1]];
    ol.coordinate.rotate(center, rotation - this.getRotation());
    ol.coordinate.add(center, anchor);
  }
  return center;
};
 
 
/**
 * @param {number} resolution Target resolution.
 * @param {ol.Coordinate} anchor Zoom anchor.
 * @return {ol.Coordinate|undefined} Center for resolution and anchor.
 */
ol.View.prototype.calculateCenterZoom = function(resolution, anchor) {
  var center;
  var currentCenter = this.getCenter();
  var currentResolution = this.getResolution();
  if (currentCenter !== undefined && currentResolution !== undefined) {
    var x = anchor[0] -
        resolution * (anchor[0] - currentCenter[0]) / currentResolution;
    var y = anchor[1] -
        resolution * (anchor[1] - currentCenter[1]) / currentResolution;
    center = [x, y];
  }
  return center;
};
 
 
/**
 * @private
 * @return {ol.Size} Viewport size or `[100, 100]` when no viewport is found.
 */
ol.View.prototype.getSizeFromViewport_ = function() {
  var size = [100, 100];
  var selector = '.ol-viewport[data-view="' + ol.getUid(this) + '"]';
  var element = document.querySelector(selector);
  if (element) {
    var metrics = getComputedStyle(element);
    size[0] = parseInt(metrics.width, 10);
    size[1] = parseInt(metrics.height, 10);
  }
  return size;
};
 
 
/**
 * Get the constrained center of this view.
 * @param {ol.Coordinate|undefined} center Center.
 * @return {ol.Coordinate|undefined} Constrained center.
 * @api
 */
ol.View.prototype.constrainCenter = function(center) {
  return this.constraints_.center(center);
};
 
 
/**
 * Get the constrained resolution of this view.
 * @param {number|undefined} resolution Resolution.
 * @param {number=} opt_delta Delta. Default is `0`.
 * @param {number=} opt_direction Direction. Default is `0`.
 * @return {number|undefined} Constrained resolution.
 * @api
 */
ol.View.prototype.constrainResolution = function(
    resolution, opt_delta, opt_direction) {
  var delta = opt_delta || 0;
  var direction = opt_direction || 0;
  return this.constraints_.resolution(resolution, delta, direction);
};
 
 
/**
 * Get the constrained rotation of this view.
 * @param {number|undefined} rotation Rotation.
 * @param {number=} opt_delta Delta. Default is `0`.
 * @return {number|undefined} Constrained rotation.
 * @api
 */
ol.View.prototype.constrainRotation = function(rotation, opt_delta) {
  var delta = opt_delta || 0;
  return this.constraints_.rotation(rotation, delta);
};
 
 
/**
 * Get the view center.
 * @return {ol.Coordinate|undefined} The center of the view.
 * @observable
 * @api
 */
ol.View.prototype.getCenter = function() {
  return /** @type {ol.Coordinate|undefined} */ (
      this.get(ol.ViewProperty.CENTER));
};
 
 
/**
 * @param {Array.<number>=} opt_hints Destination array.
 * @return {Array.<number>} Hint.
 */
ol.View.prototype.getHints = function(opt_hints) {
  if (opt_hints !== undefined) {
    opt_hints[0] = this.hints_[0];
    opt_hints[1] = this.hints_[1];
    return opt_hints;
  } else {
    return this.hints_.slice();
  }
};
 
 
/**
 * Calculate the extent for the current view state and the passed size.
 * The size is the pixel dimensions of the box into which the calculated extent
 * should fit. In most cases you want to get the extent of the entire map,
 * that is `map.getSize()`.
 * @param {ol.Size=} opt_size Box pixel size. If not provided, the size of the
 * first map that uses this view will be used.
 * @return {ol.Extent} Extent.
 * @api
 */
ol.View.prototype.calculateExtent = function(opt_size) {
  var size = opt_size || this.getSizeFromViewport_();
  var center = /** @type {!ol.Coordinate} */ (this.getCenter());
  ol.asserts.assert(center, 1); // The view center is not defined
  var resolution = /** @type {!number} */ (this.getResolution());
  ol.asserts.assert(resolution !== undefined, 2); // The view resolution is not defined
  var rotation = /** @type {!number} */ (this.getRotation());
  ol.asserts.assert(rotation !== undefined, 3); // The view rotation is not defined
 
  return ol.extent.getForViewAndSize(center, resolution, rotation, size);
};
 
 
/**
 * Get the maximum resolution of the view.
 * @return {number} The maximum resolution of the view.
 * @api
 */
ol.View.prototype.getMaxResolution = function() {
  return this.maxResolution_;
};
 
 
/**
 * Get the minimum resolution of the view.
 * @return {number} The minimum resolution of the view.
 * @api
 */
ol.View.prototype.getMinResolution = function() {
  return this.minResolution_;
};
 
 
/**
 * Get the maximum zoom level for the view.
 * @return {number} The maximum zoom level.
 * @api
 */
ol.View.prototype.getMaxZoom = function() {
  return /** @type {number} */ (this.getZoomForResolution(this.minResolution_));
};
 
 
/**
 * Set a new maximum zoom level for the view.
 * @param {number} zoom The maximum zoom level.
 * @api
 */
ol.View.prototype.setMaxZoom = function(zoom) {
  this.applyOptions_(this.getUpdatedOptions_({maxZoom: zoom}));
};
 
 
/**
 * Get the minimum zoom level for the view.
 * @return {number} The minimum zoom level.
 * @api
 */
ol.View.prototype.getMinZoom = function() {
  return /** @type {number} */ (this.getZoomForResolution(this.maxResolution_));
};
 
 
/**
 * Set a new minimum zoom level for the view.
 * @param {number} zoom The minimum zoom level.
 * @api
 */
ol.View.prototype.setMinZoom = function(zoom) {
  this.applyOptions_(this.getUpdatedOptions_({minZoom: zoom}));
};
 
 
/**
 * Get the view projection.
 * @return {ol.proj.Projection} The projection of the view.
 * @api
 */
ol.View.prototype.getProjection = function() {
  return this.projection_;
};
 
 
/**
 * Get the view resolution.
 * @return {number|undefined} The resolution of the view.
 * @observable
 * @api
 */
ol.View.prototype.getResolution = function() {
  return /** @type {number|undefined} */ (
      this.get(ol.ViewProperty.RESOLUTION));
};
 
 
/**
 * Get the resolutions for the view. This returns the array of resolutions
 * passed to the constructor of the {ol.View}, or undefined if none were given.
 * @return {Array.<number>|undefined} The resolutions of the view.
 * @api
 */
ol.View.prototype.getResolutions = function() {
  return this.resolutions_;
};
 
 
/**
 * Get the resolution for a provided extent (in map units) and size (in pixels).
 * @param {ol.Extent} extent Extent.
 * @param {ol.Size} size Box pixel size.
 * @return {number} The resolution at which the provided extent will render at
 *     the given size.
 */
ol.View.prototype.getResolutionForExtent = function(extent, size) {
  var xResolution = ol.extent.getWidth(extent) / size[0];
  var yResolution = ol.extent.getHeight(extent) / size[1];
  return Math.max(xResolution, yResolution);
};
 
 
/**
 * Return a function that returns a value between 0 and 1 for a
 * resolution. Exponential scaling is assumed.
 * @param {number=} opt_power Power.
 * @return {function(number): number} Resolution for value function.
 */
ol.View.prototype.getResolutionForValueFunction = function(opt_power) {
  var power = opt_power || 2;
  var maxResolution = this.maxResolution_;
  var minResolution = this.minResolution_;
  var max = Math.log(maxResolution / minResolution) / Math.log(power);
  return (
      /**
       * @param {number} value Value.
       * @return {number} Resolution.
       */
      function(value) {
        var resolution = maxResolution / Math.pow(power, value * max);
        return resolution;
      });
};
 
 
/**
 * Get the view rotation.
 * @return {number} The rotation of the view in radians.
 * @observable
 * @api
 */
ol.View.prototype.getRotation = function() {
  return /** @type {number} */ (this.get(ol.ViewProperty.ROTATION));
};
 
 
/**
 * Return a function that returns a resolution for a value between
 * 0 and 1. Exponential scaling is assumed.
 * @param {number=} opt_power Power.
 * @return {function(number): number} Value for resolution function.
 */
ol.View.prototype.getValueForResolutionFunction = function(opt_power) {
  var power = opt_power || 2;
  var maxResolution = this.maxResolution_;
  var minResolution = this.minResolution_;
  var max = Math.log(maxResolution / minResolution) / Math.log(power);
  return (
      /**
       * @param {number} resolution Resolution.
       * @return {number} Value.
       */
      function(resolution) {
        var value =
            (Math.log(maxResolution / resolution) / Math.log(power)) / max;
        return value;
      });
};
 
 
/**
 * @return {olx.ViewState} View state.
 */
ol.View.prototype.getState = function() {
  var center = /** @type {ol.Coordinate} */ (this.getCenter());
  var projection = this.getProjection();
  var resolution = /** @type {number} */ (this.getResolution());
  var rotation = this.getRotation();
  return /** @type {olx.ViewState} */ ({
    center: center.slice(),
    projection: projection !== undefined ? projection : null,
    resolution: resolution,
    rotation: rotation
  });
};
 
 
/**
 * Get the current zoom level. Return undefined if the current
 * resolution is undefined or not within the "resolution constraints".
 * @return {number|undefined} Zoom.
 * @api
 */
ol.View.prototype.getZoom = function() {
  var zoom;
  var resolution = this.getResolution();
  if (resolution !== undefined) {
    zoom = this.getZoomForResolution(resolution);
  }
  return zoom;
};
 
 
/**
 * Get the zoom level for a resolution.
 * @param {number} resolution The resolution.
 * @return {number|undefined} The zoom level for the provided resolution.
 * @api
 */
ol.View.prototype.getZoomForResolution = function(resolution) {
  var zoom;
  if (resolution >= this.minResolution_ && resolution <= this.maxResolution_) {
    var offset = this.minZoom_ || 0;
    var max, zoomFactor;
    if (this.resolutions_) {
      var nearest = ol.array.linearFindNearest(this.resolutions_, resolution, 1);
      offset += nearest;
      if (nearest == this.resolutions_.length - 1) {
        return offset;
      }
      max = this.resolutions_[nearest];
      zoomFactor = max / this.resolutions_[nearest + 1];
    } else {
      max = this.maxResolution_;
      zoomFactor = this.zoomFactor_;
    }
    zoom = offset + Math.log(max / resolution) / Math.log(zoomFactor);
  }
  return zoom;
};
 
 
/**
 * Fit the given geometry or extent based on the given map size and border.
 * The size is pixel dimensions of the box to fit the extent into.
 * In most cases you will want to use the map size, that is `map.getSize()`.
 * Takes care of the map angle.
 * @param {ol.geom.SimpleGeometry|ol.Extent} geometryOrExtent The geometry or
 *     extent to fit the view to.
 * @param {olx.view.FitOptions=} opt_options Options.
 * @api
 */
ol.View.prototype.fit = function(geometryOrExtent, opt_options) {
  var options = opt_options || {};
  var size = options.size;
  if (!size) {
    size = this.getSizeFromViewport_();
  }
  /** @type {ol.geom.SimpleGeometry} */
  var geometry;
  if (!(geometryOrExtent instanceof ol.geom.SimpleGeometry)) {
    ol.asserts.assert(Array.isArray(geometryOrExtent),
        24); // Invalid extent or geometry provided as `geometry`
    ol.asserts.assert(!ol.extent.isEmpty(geometryOrExtent),
        25); // Cannot fit empty extent provided as `geometry`
    geometry = ol.geom.Polygon.fromExtent(geometryOrExtent);
  } else if (geometryOrExtent.getType() === ol.geom.GeometryType.CIRCLE) {
    geometryOrExtent = geometryOrExtent.getExtent();
    geometry = ol.geom.Polygon.fromExtent(geometryOrExtent);
    geometry.rotate(this.getRotation(), ol.extent.getCenter(geometryOrExtent));
  } else {
    geometry = geometryOrExtent;
  }
 
  var padding = options.padding !== undefined ? options.padding : [0, 0, 0, 0];
  var constrainResolution = options.constrainResolution !== undefined ?
      options.constrainResolution : true;
  var nearest = options.nearest !== undefined ? options.nearest : false;
  var minResolution;
  if (options.minResolution !== undefined) {
    minResolution = options.minResolution;
  } else if (options.maxZoom !== undefined) {
    minResolution = this.constrainResolution(
        this.maxResolution_, options.maxZoom - this.minZoom_, 0);
  } else {
    minResolution = 0;
  }
  var coords = geometry.getFlatCoordinates();
 
  // calculate rotated extent
  var rotation = this.getRotation();
  var cosAngle = Math.cos(-rotation);
  var sinAngle = Math.sin(-rotation);
  var minRotX = +Infinity;
  var minRotY = +Infinity;
  var maxRotX = -Infinity;
  var maxRotY = -Infinity;
  var stride = geometry.getStride();
  for (var i = 0, ii = coords.length; i < ii; i += stride) {
    var rotX = coords[i] * cosAngle - coords[i + 1] * sinAngle;
    var rotY = coords[i] * sinAngle + coords[i + 1] * cosAngle;
    minRotX = Math.min(minRotX, rotX);
    minRotY = Math.min(minRotY, rotY);
    maxRotX = Math.max(maxRotX, rotX);
    maxRotY = Math.max(maxRotY, rotY);
  }
 
  // calculate resolution
  var resolution = this.getResolutionForExtent(
      [minRotX, minRotY, maxRotX, maxRotY],
      [size[0] - padding[1] - padding[3], size[1] - padding[0] - padding[2]]);
  resolution = isNaN(resolution) ? minResolution :
      Math.max(resolution, minResolution);
  if (constrainResolution) {
    var constrainedResolution = this.constrainResolution(resolution, 0, 0);
    if (!nearest && constrainedResolution < resolution) {
      constrainedResolution = this.constrainResolution(
          constrainedResolution, -1, 0);
    }
    resolution = constrainedResolution;
  }
 
  // calculate center
  sinAngle = -sinAngle; // go back to original rotation
  var centerRotX = (minRotX + maxRotX) / 2;
  var centerRotY = (minRotY + maxRotY) / 2;
  centerRotX += (padding[1] - padding[3]) / 2 * resolution;
  centerRotY += (padding[0] - padding[2]) / 2 * resolution;
  var centerX = centerRotX * cosAngle - centerRotY * sinAngle;
  var centerY = centerRotY * cosAngle + centerRotX * sinAngle;
  var center = [centerX, centerY];
 
  if (options.duration !== undefined) {
    this.animate({
      resolution: resolution,
      center: center,
      duration: options.duration,
      easing: options.easing
    });
  } else {
    this.setResolution(resolution);
    this.setCenter(center);
  }
};
 
 
/**
 * Center on coordinate and view position.
 * @param {ol.Coordinate} coordinate Coordinate.
 * @param {ol.Size} size Box pixel size.
 * @param {ol.Pixel} position Position on the view to center on.
 * @api
 */
ol.View.prototype.centerOn = function(coordinate, size, position) {
  // calculate rotated position
  var rotation = this.getRotation();
  var cosAngle = Math.cos(-rotation);
  var sinAngle = Math.sin(-rotation);
  var rotX = coordinate[0] * cosAngle - coordinate[1] * sinAngle;
  var rotY = coordinate[1] * cosAngle + coordinate[0] * sinAngle;
  var resolution = this.getResolution();
  rotX += (size[0] / 2 - position[0]) * resolution;
  rotY += (position[1] - size[1] / 2) * resolution;
 
  // go back to original angle
  sinAngle = -sinAngle; // go back to original rotation
  var centerX = rotX * cosAngle - rotY * sinAngle;
  var centerY = rotY * cosAngle + rotX * sinAngle;
 
  this.setCenter([centerX, centerY]);
};
 
 
/**
 * @return {boolean} Is defined.
 */
ol.View.prototype.isDef = function() {
  return !!this.getCenter() && this.getResolution() !== undefined;
};
 
 
/**
 * Rotate the view around a given coordinate.
 * @param {number} rotation New rotation value for the view.
 * @param {ol.Coordinate=} opt_anchor The rotation center.
 * @api
 */
ol.View.prototype.rotate = function(rotation, opt_anchor) {
  if (opt_anchor !== undefined) {
    var center = this.calculateCenterRotate(rotation, opt_anchor);
    this.setCenter(center);
  }
  this.setRotation(rotation);
};
 
 
/**
 * Set the center of the current view.
 * @param {ol.Coordinate|undefined} center The center of the view.
 * @observable
 * @api
 */
ol.View.prototype.setCenter = function(center) {
  this.set(ol.ViewProperty.CENTER, center);
  if (this.getAnimating()) {
    this.cancelAnimations();
  }
};
 
 
/**
 * @param {ol.ViewHint} hint Hint.
 * @param {number} delta Delta.
 * @return {number} New value.
 */
ol.View.prototype.setHint = function(hint, delta) {
  this.hints_[hint] += delta;
  this.changed();
  return this.hints_[hint];
};
 
 
/**
 * Set the resolution for this view.
 * @param {number|undefined} resolution The resolution of the view.
 * @observable
 * @api
 */
ol.View.prototype.setResolution = function(resolution) {
  this.set(ol.ViewProperty.RESOLUTION, resolution);
  if (this.getAnimating()) {
    this.cancelAnimations();
  }
};
 
 
/**
 * Set the rotation for this view.
 * @param {number} rotation The rotation of the view in radians.
 * @observable
 * @api
 */
ol.View.prototype.setRotation = function(rotation) {
  this.set(ol.ViewProperty.ROTATION, rotation);
  if (this.getAnimating()) {
    this.cancelAnimations();
  }
};
 
 
/**
 * Zoom to a specific zoom level.
 * @param {number} zoom Zoom level.
 * @api
 */
ol.View.prototype.setZoom = function(zoom) {
  var resolution = this.constrainResolution(
      this.maxResolution_, zoom - this.minZoom_, 0);
  this.setResolution(resolution);
};
 
 
/**
 * @param {olx.ViewOptions} options View options.
 * @private
 * @return {ol.CenterConstraintType} The constraint.
 */
ol.View.createCenterConstraint_ = function(options) {
  if (options.extent !== undefined) {
    return ol.CenterConstraint.createExtent(options.extent);
  } else {
    return ol.CenterConstraint.none;
  }
};
 
 
/**
 * @private
 * @param {olx.ViewOptions} options View options.
 * @return {{constraint: ol.ResolutionConstraintType, maxResolution: number,
 *     minResolution: number, zoomFactor: number}} The constraint.
 */
ol.View.createResolutionConstraint_ = function(options) {
  var resolutionConstraint;
  var maxResolution;
  var minResolution;
 
  // TODO: move these to be ol constants
  // see https://github.com/openlayers/openlayers/issues/2076
  var defaultMaxZoom = 28;
  var defaultZoomFactor = 2;
 
  var minZoom = options.minZoom !== undefined ?
      options.minZoom : ol.DEFAULT_MIN_ZOOM;
 
  var maxZoom = options.maxZoom !== undefined ?
      options.maxZoom : defaultMaxZoom;
 
  var zoomFactor = options.zoomFactor !== undefined ?
      options.zoomFactor : defaultZoomFactor;
 
  if (options.resolutions !== undefined) {
    var resolutions = options.resolutions;
    maxResolution = resolutions[0];
    minResolution = resolutions[resolutions.length - 1];
    resolutionConstraint = ol.ResolutionConstraint.createSnapToResolutions(
        resolutions);
  } else {
    // calculate the default min and max resolution
    var projection = ol.proj.createProjection(options.projection, 'EPSG:3857');
    var extent = projection.getExtent();
    var size = !extent ?
        // use an extent that can fit the whole world if need be
        360 * ol.proj.METERS_PER_UNIT[ol.proj.Units.DEGREES] /
            projection.getMetersPerUnit() :
        Math.max(ol.extent.getWidth(extent), ol.extent.getHeight(extent));
 
    var defaultMaxResolution = size / ol.DEFAULT_TILE_SIZE / Math.pow(
        defaultZoomFactor, ol.DEFAULT_MIN_ZOOM);
 
    var defaultMinResolution = defaultMaxResolution / Math.pow(
        defaultZoomFactor, defaultMaxZoom - ol.DEFAULT_MIN_ZOOM);
 
    // user provided maxResolution takes precedence
    maxResolution = options.maxResolution;
    if (maxResolution !== undefined) {
      minZoom = 0;
    } else {
      maxResolution = defaultMaxResolution / Math.pow(zoomFactor, minZoom);
    }
 
    // user provided minResolution takes precedence
    minResolution = options.minResolution;
    if (minResolution === undefined) {
      if (options.maxZoom !== undefined) {
        if (options.maxResolution !== undefined) {
          minResolution = maxResolution / Math.pow(zoomFactor, maxZoom);
        } else {
          minResolution = defaultMaxResolution / Math.pow(zoomFactor, maxZoom);
        }
      } else {
        minResolution = defaultMinResolution;
      }
    }
 
    // given discrete zoom levels, minResolution may be different than provided
    maxZoom = minZoom + Math.floor(
        Math.log(maxResolution / minResolution) / Math.log(zoomFactor));
    minResolution = maxResolution / Math.pow(zoomFactor, maxZoom - minZoom);
 
    resolutionConstraint = ol.ResolutionConstraint.createSnapToPower(
        zoomFactor, maxResolution, maxZoom - minZoom);
  }
  return {constraint: resolutionConstraint, maxResolution: maxResolution,
    minResolution: minResolution, minZoom: minZoom, zoomFactor: zoomFactor};
};
 
 
/**
 * @private
 * @param {olx.ViewOptions} options View options.
 * @return {ol.RotationConstraintType} Rotation constraint.
 */
ol.View.createRotationConstraint_ = function(options) {
  var enableRotation = options.enableRotation !== undefined ?
      options.enableRotation : true;
  if (enableRotation) {
    var constrainRotation = options.constrainRotation;
    if (constrainRotation === undefined || constrainRotation === true) {
      return ol.RotationConstraint.createSnapToZero();
    } else if (constrainRotation === false) {
      return ol.RotationConstraint.none;
    } else if (typeof constrainRotation === 'number') {
      return ol.RotationConstraint.createSnapToN(constrainRotation);
    } else {
      return ol.RotationConstraint.none;
    }
  } else {
    return ol.RotationConstraint.disable;
  }
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/viewhint.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/viewhint.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 112                    
goog.provide('ol.ViewHint');
 
/**
 * @enum {number}
 */
ol.ViewHint = {
  ANIMATING: 0,
  INTERACTING: 1
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/viewproperty.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/viewproperty.js

Statements: 50% (1 / 2)      Branches: 100% (0 / 0)      Functions: 100% (0 / 0)      Lines: 50% (1 / 2)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 122                      
goog.provide('ol.ViewProperty');
 
/**
 * @enum {string}
 */
ol.ViewProperty = {
  CENTER: 'center',
  RESOLUTION: 'resolution',
  ROTATION: 'rotation'
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/webgl.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/webgl.js

Statements: 2.13% (1 / 47)      Branches: 0% (0 / 4)      Functions: 0% (0 / 1)      Lines: 2.13% (1 / 47)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 2962                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              
goog.provide('ol.webgl');
 
goog.require('ol');
 
 
if (ol.ENABLE_WEBGL) {
 
  /** Constants taken from goog.webgl
   */
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.ONE = 1;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.SRC_ALPHA = 0x0302;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.COLOR_ATTACHMENT0 = 0x8CE0;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.COLOR_BUFFER_BIT = 0x00004000;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.TRIANGLES = 0x0004;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.TRIANGLE_STRIP = 0x0005;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.ONE_MINUS_SRC_ALPHA = 0x0303;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.ARRAY_BUFFER = 0x8892;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.ELEMENT_ARRAY_BUFFER = 0x8893;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.STREAM_DRAW = 0x88E0;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.STATIC_DRAW = 0x88E4;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.DYNAMIC_DRAW = 0x88E8;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.CULL_FACE = 0x0B44;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.BLEND = 0x0BE2;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.STENCIL_TEST = 0x0B90;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.DEPTH_TEST = 0x0B71;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.SCISSOR_TEST = 0x0C11;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.UNSIGNED_BYTE = 0x1401;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.UNSIGNED_SHORT = 0x1403;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.UNSIGNED_INT = 0x1405;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.FLOAT = 0x1406;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.RGBA = 0x1908;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.FRAGMENT_SHADER = 0x8B30;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.VERTEX_SHADER = 0x8B31;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.LINK_STATUS = 0x8B82;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.LINEAR = 0x2601;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.TEXTURE_MAG_FILTER = 0x2800;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.TEXTURE_MIN_FILTER = 0x2801;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.TEXTURE_WRAP_S = 0x2802;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.TEXTURE_WRAP_T = 0x2803;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.TEXTURE_2D = 0x0DE1;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.TEXTURE0 = 0x84C0;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.CLAMP_TO_EDGE = 0x812F;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.COMPILE_STATUS = 0x8B81;
 
 
  /**
   * @const
   * @type {number}
   */
  ol.webgl.FRAMEBUFFER = 0x8D40;
 
 
  /** end of goog.webgl constants
   */
 
 
  /**
   * @const
   * @private
   * @type {Array.<string>}
   */
  ol.webgl.CONTEXT_IDS_ = [
    'experimental-webgl',
    'webgl',
    'webkit-3d',
    'moz-webgl'
  ];
 
 
  /**
   * @param {HTMLCanvasElement} canvas Canvas.
   * @param {Object=} opt_attributes Attributes.
   * @return {WebGLRenderingContext} WebGL rendering context.
   */
  ol.webgl.getContext = function(canvas, opt_attributes) {
    var context, i, ii = ol.webgl.CONTEXT_IDS_.length;
    for (i = 0; i < ii; ++i) {
      try {
        context = canvas.getContext(ol.webgl.CONTEXT_IDS_[i], opt_attributes);
        if (context) {
          return /** @type {!WebGLRenderingContext} */ (context);
        }
      } catch (e) {
        // pass
      }
    }
    return null;
  };
 
}
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/xml.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/src/ol/xml.js

Statements: 0.79% (1 / 127)      Branches: 0% (0 / 54)      Functions: 0% (0 / 30)      Lines: 0.79% (1 / 127)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 5102                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          
goog.provide('ol.xml');
 
goog.require('ol.array');
 
 
/**
 * This document should be used when creating nodes for XML serializations. This
 * document is also used by {@link ol.xml.createElementNS} and
 * {@link ol.xml.setAttributeNS}
 * @const
 * @type {Document}
 */
ol.xml.DOCUMENT = document.implementation.createDocument('', '', null);
 
 
/**
 * @param {string} namespaceURI Namespace URI.
 * @param {string} qualifiedName Qualified name.
 * @return {Node} Node.
 */
ol.xml.createElementNS = function(namespaceURI, qualifiedName) {
  return ol.xml.DOCUMENT.createElementNS(namespaceURI, qualifiedName);
};
 
 
/**
 * Recursively grab all text content of child nodes into a single string.
 * @param {Node} node Node.
 * @param {boolean} normalizeWhitespace Normalize whitespace: remove all line
 * breaks.
 * @return {string} All text content.
 * @api
 */
ol.xml.getAllTextContent = function(node, normalizeWhitespace) {
  return ol.xml.getAllTextContent_(node, normalizeWhitespace, []).join('');
};
 
 
/**
 * Recursively grab all text content of child nodes into a single string.
 * @param {Node} node Node.
 * @param {boolean} normalizeWhitespace Normalize whitespace: remove all line
 * breaks.
 * @param {Array.<string>} accumulator Accumulator.
 * @private
 * @return {Array.<string>} Accumulator.
 */
ol.xml.getAllTextContent_ = function(node, normalizeWhitespace, accumulator) {
  if (node.nodeType == Node.CDATA_SECTION_NODE ||
      node.nodeType == Node.TEXT_NODE) {
    if (normalizeWhitespace) {
      accumulator.push(String(node.nodeValue).replace(/(\r\n|\r|\n)/g, ''));
    } else {
      accumulator.push(node.nodeValue);
    }
  } else {
    var n;
    for (n = node.firstChild; n; n = n.nextSibling) {
      ol.xml.getAllTextContent_(n, normalizeWhitespace, accumulator);
    }
  }
  return accumulator;
};
 
 
/**
 * @param {?} value Value.
 * @return {boolean} Is document.
 */
ol.xml.isDocument = function(value) {
  return value instanceof Document;
};
 
 
/**
 * @param {?} value Value.
 * @return {boolean} Is node.
 */
ol.xml.isNode = function(value) {
  return value instanceof Node;
};
 
 
/**
 * @param {Node} node Node.
 * @param {?string} namespaceURI Namespace URI.
 * @param {string} name Attribute name.
 * @return {string} Value
 */
ol.xml.getAttributeNS = function(node, namespaceURI, name) {
  return node.getAttributeNS(namespaceURI, name) || '';
};
 
 
/**
 * @param {Node} node Node.
 * @param {?string} namespaceURI Namespace URI.
 * @param {string} name Attribute name.
 * @param {string|number} value Value.
 */
ol.xml.setAttributeNS = function(node, namespaceURI, name, value) {
  node.setAttributeNS(namespaceURI, name, value);
};
 
 
/**
 * Parse an XML string to an XML Document.
 * @param {string} xml XML.
 * @return {Document} Document.
 * @api
 */
ol.xml.parse = function(xml) {
  return new DOMParser().parseFromString(xml, 'application/xml');
};
 
 
/**
 * Make an array extender function for extending the array at the top of the
 * object stack.
 * @param {function(this: T, Node, Array.<*>): (Array.<*>|undefined)}
 *     valueReader Value reader.
 * @param {T=} opt_this The object to use as `this` in `valueReader`.
 * @return {ol.XmlParser} Parser.
 * @template T
 */
ol.xml.makeArrayExtender = function(valueReader, opt_this) {
  return (
      /**
       * @param {Node} node Node.
       * @param {Array.<*>} objectStack Object stack.
       */
      function(node, objectStack) {
        var value = valueReader.call(opt_this, node, objectStack);
        if (value !== undefined) {
          var array = /** @type {Array.<*>} */
              (objectStack[objectStack.length - 1]);
          ol.array.extend(array, value);
        }
      });
};
 
 
/**
 * Make an array pusher function for pushing to the array at the top of the
 * object stack.
 * @param {function(this: T, Node, Array.<*>): *} valueReader Value reader.
 * @param {T=} opt_this The object to use as `this` in `valueReader`.
 * @return {ol.XmlParser} Parser.
 * @template T
 */
ol.xml.makeArrayPusher = function(valueReader, opt_this) {
  return (
      /**
       * @param {Node} node Node.
       * @param {Array.<*>} objectStack Object stack.
       */
      function(node, objectStack) {
        var value = valueReader.call(opt_this !== undefined ? opt_this : this,
            node, objectStack);
        if (value !== undefined) {
          var array = objectStack[objectStack.length - 1];
          array.push(value);
        }
      });
};
 
 
/**
 * Make an object stack replacer function for replacing the object at the
 * top of the stack.
 * @param {function(this: T, Node, Array.<*>): *} valueReader Value reader.
 * @param {T=} opt_this The object to use as `this` in `valueReader`.
 * @return {ol.XmlParser} Parser.
 * @template T
 */
ol.xml.makeReplacer = function(valueReader, opt_this) {
  return (
      /**
       * @param {Node} node Node.
       * @param {Array.<*>} objectStack Object stack.
       */
      function(node, objectStack) {
        var value = valueReader.call(opt_this !== undefined ? opt_this : this,
            node, objectStack);
        if (value !== undefined) {
          objectStack[objectStack.length - 1] = value;
        }
      });
};
 
 
/**
 * Make an object property pusher function for adding a property to the
 * object at the top of the stack.
 * @param {function(this: T, Node, Array.<*>): *} valueReader Value reader.
 * @param {string=} opt_property Property.
 * @param {T=} opt_this The object to use as `this` in `valueReader`.
 * @return {ol.XmlParser} Parser.
 * @template T
 */
ol.xml.makeObjectPropertyPusher = function(valueReader, opt_property, opt_this) {
  return (
      /**
       * @param {Node} node Node.
       * @param {Array.<*>} objectStack Object stack.
       */
      function(node, objectStack) {
        var value = valueReader.call(opt_this !== undefined ? opt_this : this,
            node, objectStack);
        if (value !== undefined) {
          var object = /** @type {Object} */
              (objectStack[objectStack.length - 1]);
          var property = opt_property !== undefined ?
              opt_property : node.localName;
          var array;
          if (property in object) {
            array = object[property];
          } else {
            array = object[property] = [];
          }
          array.push(value);
        }
      });
};
 
 
/**
 * Make an object property setter function.
 * @param {function(this: T, Node, Array.<*>): *} valueReader Value reader.
 * @param {string=} opt_property Property.
 * @param {T=} opt_this The object to use as `this` in `valueReader`.
 * @return {ol.XmlParser} Parser.
 * @template T
 */
ol.xml.makeObjectPropertySetter = function(valueReader, opt_property, opt_this) {
  return (
      /**
       * @param {Node} node Node.
       * @param {Array.<*>} objectStack Object stack.
       */
      function(node, objectStack) {
        var value = valueReader.call(opt_this !== undefined ? opt_this : this,
            node, objectStack);
        if (value !== undefined) {
          var object = /** @type {Object} */
              (objectStack[objectStack.length - 1]);
          var property = opt_property !== undefined ?
              opt_property : node.localName;
          object[property] = value;
        }
      });
};
 
 
/**
 * Create a serializer that appends nodes written by its `nodeWriter` to its
 * designated parent. The parent is the `node` of the
 * {@link ol.XmlNodeStackItem} at the top of the `objectStack`.
 * @param {function(this: T, Node, V, Array.<*>)}
 *     nodeWriter Node writer.
 * @param {T=} opt_this The object to use as `this` in `nodeWriter`.
 * @return {ol.XmlSerializer} Serializer.
 * @template T, V
 */
ol.xml.makeChildAppender = function(nodeWriter, opt_this) {
  return function(node, value, objectStack) {
    nodeWriter.call(opt_this !== undefined ? opt_this : this,
        node, value, objectStack);
    var parent = objectStack[objectStack.length - 1];
    var parentNode = parent.node;
    parentNode.appendChild(node);
  };
};
 
 
/**
 * Create a serializer that calls the provided `nodeWriter` from
 * {@link ol.xml.serialize}. This can be used by the parent writer to have the
 * 'nodeWriter' called with an array of values when the `nodeWriter` was
 * designed to serialize a single item. An example would be a LineString
 * geometry writer, which could be reused for writing MultiLineString
 * geometries.
 * @param {function(this: T, Node, V, Array.<*>)}
 *     nodeWriter Node writer.
 * @param {T=} opt_this The object to use as `this` in `nodeWriter`.
 * @return {ol.XmlSerializer} Serializer.
 * @template T, V
 */
ol.xml.makeArraySerializer = function(nodeWriter, opt_this) {
  var serializersNS, nodeFactory;
  return function(node, value, objectStack) {
    if (serializersNS === undefined) {
      serializersNS = {};
      var serializers = {};
      serializers[node.localName] = nodeWriter;
      serializersNS[node.namespaceURI] = serializers;
      nodeFactory = ol.xml.makeSimpleNodeFactory(node.localName);
    }
    ol.xml.serialize(serializersNS, nodeFactory, value, objectStack);
  };
};
 
 
/**
 * Create a node factory which can use the `opt_keys` passed to
 * {@link ol.xml.serialize} or {@link ol.xml.pushSerializeAndPop} as node names,
 * or a fixed node name. The namespace of the created nodes can either be fixed,
 * or the parent namespace will be used.
 * @param {string=} opt_nodeName Fixed node name which will be used for all
 *     created nodes. If not provided, the 3rd argument to the resulting node
 *     factory needs to be provided and will be the nodeName.
 * @param {string=} opt_namespaceURI Fixed namespace URI which will be used for
 *     all created nodes. If not provided, the namespace of the parent node will
 *     be used.
 * @return {function(*, Array.<*>, string=): (Node|undefined)} Node factory.
 */
ol.xml.makeSimpleNodeFactory = function(opt_nodeName, opt_namespaceURI) {
  var fixedNodeName = opt_nodeName;
  return (
      /**
       * @param {*} value Value.
       * @param {Array.<*>} objectStack Object stack.
       * @param {string=} opt_nodeName Node name.
       * @return {Node} Node.
       */
      function(value, objectStack, opt_nodeName) {
        var context = objectStack[objectStack.length - 1];
        var node = context.node;
        var nodeName = fixedNodeName;
        if (nodeName === undefined) {
          nodeName = opt_nodeName;
        }
        var namespaceURI = opt_namespaceURI;
        if (opt_namespaceURI === undefined) {
          namespaceURI = node.namespaceURI;
        }
        return ol.xml.createElementNS(namespaceURI, /** @type {string} */ (nodeName));
      }
  );
};
 
 
/**
 * A node factory that creates a node using the parent's `namespaceURI` and the
 * `nodeName` passed by {@link ol.xml.serialize} or
 * {@link ol.xml.pushSerializeAndPop} to the node factory.
 * @const
 * @type {function(*, Array.<*>, string=): (Node|undefined)}
 */
ol.xml.OBJECT_PROPERTY_NODE_FACTORY = ol.xml.makeSimpleNodeFactory();
 
 
/**
 * Create an array of `values` to be used with {@link ol.xml.serialize} or
 * {@link ol.xml.pushSerializeAndPop}, where `orderedKeys` has to be provided as
 * `opt_key` argument.
 * @param {Object.<string, V>} object Key-value pairs for the sequence. Keys can
 *     be a subset of the `orderedKeys`.
 * @param {Array.<string>} orderedKeys Keys in the order of the sequence.
 * @return {Array.<V>} Values in the order of the sequence. The resulting array
 *     has the same length as the `orderedKeys` array. Values that are not
 *     present in `object` will be `undefined` in the resulting array.
 * @template V
 */
ol.xml.makeSequence = function(object, orderedKeys) {
  var length = orderedKeys.length;
  var sequence = new Array(length);
  for (var i = 0; i < length; ++i) {
    sequence[i] = object[orderedKeys[i]];
  }
  return sequence;
};
 
 
/**
 * Create a namespaced structure, using the same values for each namespace.
 * This can be used as a starting point for versioned parsers, when only a few
 * values are version specific.
 * @param {Array.<string>} namespaceURIs Namespace URIs.
 * @param {T} structure Structure.
 * @param {Object.<string, T>=} opt_structureNS Namespaced structure to add to.
 * @return {Object.<string, T>} Namespaced structure.
 * @template T
 */
ol.xml.makeStructureNS = function(namespaceURIs, structure, opt_structureNS) {
  /**
   * @type {Object.<string, *>}
   */
  var structureNS = opt_structureNS !== undefined ? opt_structureNS : {};
  var i, ii;
  for (i = 0, ii = namespaceURIs.length; i < ii; ++i) {
    structureNS[namespaceURIs[i]] = structure;
  }
  return structureNS;
};
 
 
/**
 * Parse a node using the parsers and object stack.
 * @param {Object.<string, Object.<string, ol.XmlParser>>} parsersNS
 *     Parsers by namespace.
 * @param {Node} node Node.
 * @param {Array.<*>} objectStack Object stack.
 * @param {*=} opt_this The object to use as `this`.
 */
ol.xml.parseNode = function(parsersNS, node, objectStack, opt_this) {
  var n;
  for (n = node.firstElementChild; n; n = n.nextElementSibling) {
    var parsers = parsersNS[n.namespaceURI];
    if (parsers !== undefined) {
      var parser = parsers[n.localName];
      if (parser !== undefined) {
        parser.call(opt_this, n, objectStack);
      }
    }
  }
};
 
 
/**
 * Push an object on top of the stack, parse and return the popped object.
 * @param {T} object Object.
 * @param {Object.<string, Object.<string, ol.XmlParser>>} parsersNS
 *     Parsers by namespace.
 * @param {Node} node Node.
 * @param {Array.<*>} objectStack Object stack.
 * @param {*=} opt_this The object to use as `this`.
 * @return {T} Object.
 * @template T
 */
ol.xml.pushParseAndPop = function(
    object, parsersNS, node, objectStack, opt_this) {
  objectStack.push(object);
  ol.xml.parseNode(parsersNS, node, objectStack, opt_this);
  return objectStack.pop();
};
 
 
/**
 * Walk through an array of `values` and call a serializer for each value.
 * @param {Object.<string, Object.<string, ol.XmlSerializer>>} serializersNS
 *     Namespaced serializers.
 * @param {function(this: T, *, Array.<*>, (string|undefined)): (Node|undefined)} nodeFactory
 *     Node factory. The `nodeFactory` creates the node whose namespace and name
 *     will be used to choose a node writer from `serializersNS`. This
 *     separation allows us to decide what kind of node to create, depending on
 *     the value we want to serialize. An example for this would be different
 *     geometry writers based on the geometry type.
 * @param {Array.<*>} values Values to serialize. An example would be an array
 *     of {@link ol.Feature} instances.
 * @param {Array.<*>} objectStack Node stack.
 * @param {Array.<string>=} opt_keys Keys of the `values`. Will be passed to the
 *     `nodeFactory`. This is used for serializing object literals where the
 *     node name relates to the property key. The array length of `opt_keys` has
 *     to match the length of `values`. For serializing a sequence, `opt_keys`
 *     determines the order of the sequence.
 * @param {T=} opt_this The object to use as `this` for the node factory and
 *     serializers.
 * @template T
 */
ol.xml.serialize = function(
    serializersNS, nodeFactory, values, objectStack, opt_keys, opt_this) {
  var length = (opt_keys !== undefined ? opt_keys : values).length;
  var value, node;
  for (var i = 0; i < length; ++i) {
    value = values[i];
    if (value !== undefined) {
      node = nodeFactory.call(opt_this, value, objectStack,
          opt_keys !== undefined ? opt_keys[i] : undefined);
      if (node !== undefined) {
        serializersNS[node.namespaceURI][node.localName]
            .call(opt_this, node, value, objectStack);
      }
    }
  }
};
 
 
/**
 * @param {O} object Object.
 * @param {Object.<string, Object.<string, ol.XmlSerializer>>} serializersNS
 *     Namespaced serializers.
 * @param {function(this: T, *, Array.<*>, (string|undefined)): (Node|undefined)} nodeFactory
 *     Node factory. The `nodeFactory` creates the node whose namespace and name
 *     will be used to choose a node writer from `serializersNS`. This
 *     separation allows us to decide what kind of node to create, depending on
 *     the value we want to serialize. An example for this would be different
 *     geometry writers based on the geometry type.
 * @param {Array.<*>} values Values to serialize. An example would be an array
 *     of {@link ol.Feature} instances.
 * @param {Array.<*>} objectStack Node stack.
 * @param {Array.<string>=} opt_keys Keys of the `values`. Will be passed to the
 *     `nodeFactory`. This is used for serializing object literals where the
 *     node name relates to the property key. The array length of `opt_keys` has
 *     to match the length of `values`. For serializing a sequence, `opt_keys`
 *     determines the order of the sequence.
 * @param {T=} opt_this The object to use as `this` for the node factory and
 *     serializers.
 * @return {O|undefined} Object.
 * @template O, T
 */
ol.xml.pushSerializeAndPop = function(object,
    serializersNS, nodeFactory, values, objectStack, opt_keys, opt_this) {
  objectStack.push(object);
  ol.xml.serialize(
      serializersNS, nodeFactory, values, objectStack, opt_keys, opt_this);
  return objectStack.pop();
};
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/

Statements: 23.3% (120 / 515)      Branches: 11.11% (20 / 180)      Functions: 13.13% (13 / 99)      Lines: 23.3% (120 / 515)      Ignored: none     

All files » node-npmtest-openlayers/node_modules/openlayers/tasks/
File Statements Branches Functions Lines
build-ext.js 68.29% (28 / 41) 43.75% (7 / 16) 80% (8 / 10) 68.29% (28 / 41)
generate-exports.js 14.13% (13 / 92) 3.13% (1 / 32) 0% (0 / 18) 14.13% (13 / 92)
generate-externs.js 12.84% (14 / 109) 2.27% (1 / 44) 0% (0 / 15) 12.84% (14 / 109)
generate-info.js 23.88% (32 / 134) 8.7% (4 / 46) 3.33% (1 / 30) 23.88% (32 / 134)
generate-requires.js 82.35% (14 / 17) 62.5% (5 / 8) 75% (3 / 4) 82.35% (14 / 17)
install.js 66.67% (4 / 6) 50% (1 / 2) 100% (1 / 1) 66.67% (4 / 6)
serve-lib.js 20.93% (9 / 43) 8.33% (1 / 12) 0% (0 / 9) 20.93% (9 / 43)
serve.js 8.22% (6 / 73) 0% (0 / 20) 0% (0 / 12) 8.22% (6 / 73)
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/build-ext.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/build-ext.js

Statements: 68.29% (28 / 41)      Branches: 43.75% (7 / 16)      Functions: 80% (8 / 10)      Lines: 68.29% (28 / 41)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 1251 1   1 1 1   1   1 1             1 1 4               4                                 1 4 4                                       4 4 4       4                                     1 1 4 4                       1 1 1     1                     1    
var fs = require('fs-extra');
var path = require('path');
 
var async = require('async');
var browserify = require('browserify');
var derequire = require('derequire');
 
var pkg = require('../package.json');
 
var root = path.join(__dirname, '..');
var buildDir = path.join(root, 'build', 'ol.ext');
 
 
/**
 * Get external module metadata.
 * @return {Array.<Object>} Array of objects representing external modules.
 */
function getExternalModules() {
  return pkg.ext.map(function(item) {
    Iif (typeof item === 'string') {
      return {
        name: item,
        module: item,
        main: require.resolve(item),
        browserify: false
      };
    } else {
      return {
        module: item.module,
        name: item.name !== undefined ? item.name : item.module,
        main: require.resolve(item.module),
        browserify: item.browserify !== undefined ? item.browserify : false
      };
    }
  });
}
 
 
/**
 * Wrap a CommonJS module in Closure Library accessible code.
 * @param {Object} mod Module metadata.
 * @param {function(Error, string)} callback Called with any error and the
 *     wrapped module.
 */
function wrapModule(mod, callback) {
  var wrap = function(code) {
    return 'goog.provide(\'ol.ext.' + mod.name + '\');\n' +
        '/** @typedef {function(*)} */\n' +
        'ol.ext.' + mod.name + ';\n' +
        '(function() {\n' +
        'var exports = {};\n' +
        'var module = {exports: exports};\n' +
        'var define;\n' +
        '/**\n' +
        ' * @fileoverview\n' +
        ' * @suppress {accessControls, ambiguousFunctionDecl, ' +
        'checkDebuggerStatement, checkRegExp, checkTypes, checkVars, const, ' +
        'constantProperty, deprecated, duplicate, es5Strict, ' +
        'fileoverviewTags, missingProperties, nonStandardJsDocs, ' +
        'strictModuleDepCheck, suspiciousCode, undefinedNames, ' +
        'undefinedVars, unknownDefines, unusedLocalVariables, uselessCode, visibility}\n' +
        ' */\n' + code + '\n' +
        'ol.ext.' + mod.name + ' = module.exports;\n' +
        '})();\n';
  };
 
  Eif (mod.browserify) {
    browserify(mod.main, {standalone: mod.name}).bundle(function(err, buf) {
      Iif (err) {
        callback(err);
        return;
      }
      callback(null, wrap(derequire(buf.toString())));
    });
  } else {
    fs.readFile(mod.main, function(err, data) {
      if (err) {
        callback(err);
        return;
      }
      callback(null, wrap(data.toString()));
    });
  }
}
 
 
/**
 * Build external modules.
 * @param {Array.<Object>} modules External modules.
 * @param {function(Error)} callback Called with any error.
 */
function buildModules(modules, callback) {
  async.each(modules, function(mod, done) {
    var output = path.join(buildDir, mod.name) + '.js';
    async.waterfall([
      wrapModule.bind(null, mod),
      fs.outputFile.bind(fs, output)
    ], done);
  }, callback);
}
 
 
/**
 * Build all external modules.
 * @param {function(Error)} callback Called with any error.
 */
function main(callback) {
  var modules = getExternalModules();
  buildModules(modules, callback);
}
 
Iif (require.main === module) {
  main(function(err) {
    if (err) {
      process.stderr.write(err.message + '\n');
      process.exit(1);
    } else {
      process.exit(0);
    }
  });
}
 
module.exports = main;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/generate-exports.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/generate-exports.js

Statements: 14.13% (13 / 92)      Branches: 3.13% (1 / 32)      Functions: 0% (0 / 18)      Lines: 14.13% (13 / 92)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 2451   1 1   1                     1                                                                                 1                                               1                                                                                             1                         1                                   1                                                           1                                         1                                                               1    
var fs = require('fs-extra');
 
var async = require('async');
var nomnom = require('nomnom');
 
var generateInfo = require('./generate-info');
 
 
/**
 * Get the configuration from the config file.  If configPath is provided
 * it is assumed to be a JSON file with an 'exports' member that is a list
 * of symbol names or patterns.
 *
 * @param {string} configPath Path to config file.
 * @param {function(Error, Object)} callback Called with config object.
 */
function getConfig(configPath, callback) {
  if (configPath) {
    fs.readFile(configPath, function(err, data) {
      if (err) {
        callback(err);
        return;
      }
      var obj;
      try {
        obj = JSON.parse(String(data));
      } catch (err2) {
        callback(new Error('Trouble parsing file as JSON: ' + configPath));
        return;
      }
      var patterns = obj.exports;
      if (patterns && !Array.isArray(patterns)) {
        callback(new Error('Expected an exports array, got: ' + patterns));
        return;
      }
      var namespace = obj.namespace;
      if (namespace && typeof namespace !== 'string') {
        callback(new Error('Expected an namespace string, got: ' +
            namespace));
        return;
      }
      callback(null, obj);
    });
  } else {
    process.nextTick(function() {
      callback(null, {exports: ['*']});
    });
  }
}
 
 
/**
 * Read the symbols from info file.
 * @param {Array.<string>} patterns List of patterns to pass along.
 * @param {function(Error, Array.<string>, Array.<Object>)} callback Called
 *     with the patterns and symbols (or any error).
 */
function getSymbols(patterns, callback) {
  generateInfo(function(err) {
    if (err) {
      callback(new Error('Trouble generating info: ' + err.message));
      return;
    }
    var symbols = require('../build/info.json').symbols;
    callback(null, patterns, symbols);
  });
}
 
 
/**
 * Generate a list of symbol names given a list of patterns.  Patterns may
 * include a * wildcard at the end of the string, in which case all symbol names
 * that start with the preceding string will be matched (e.g 'foo.Bar#*' will
 * match all symbol names that start with 'foo.Bar#').
 *
 * @param {Array.<string>} patterns A list of symbol names to match.  Wildcards
 *     at the end of a string will match multiple names.
 * @param {Array.<Object>} symbols List of symbols.
 * @param {function(Error, Array.<Object>, Array.<string>)} callback Called with
 *     the filtered list of symbols and a list of all provides (or any error).
 */
function filterSymbols(patterns, symbols, callback) {
  var matches = [];
 
  var provides = {};
  var lookup = {};
  symbols.forEach(function(symbol) {
    lookup[symbol.name] = symbol;
    symbol.provides.forEach(function(provide) {
      provides[provide] = true;
    });
  });
 
  patterns.forEach(function(name) {
    var match = false;
    var pattern = (name.substr(-1) === '*');
    if (pattern) {
      name = name.substr(0, name.length - 1);
      symbols.forEach(function(symbol) {
        if (symbol.name.indexOf(name) === 0) {
          matches.push(symbol);
          match = true;
        }
      });
    } else {
      var symbol = lookup[name];
      if (symbol) {
        matches.push(symbol);
        match = true;
      }
    }
    if (!match) {
      var message = 'No matching symbol found: ' + name + (pattern ? '*' : '');
      callback(new Error(message));
    }
  });
 
  callback(null, matches, Object.keys(provides).sort());
}
 
 
/**
 * Generate goog code to export a named symbol.
 * @param {string} name Symbol name.
 * @param {string|undefined} namespace Target object for exported
 *     symbols.
 * @return {string} Export code.
 */
function formatSymbolExport(name, namespace) {
  return 'goog.exportSymbol(\n' +
      '    \'' + name + '\',\n' +
      '    ' + name +
      (namespace ? ',\n    ' + namespace : '') + ');\n';
}
 
 
/**
 * Generate goog code to export a property.
 * @param {string} name Property long name (e.g. foo.Bar#baz).
 * @return {string} Export code.
 */
function formatPropertyExport(name) {
  var parts = name.split('#');
  var prototype = parts[0] + '.prototype';
  var property = parts[1];
  return 'goog.exportProperty(\n' +
      '    ' + prototype + ',\n' +
      '    \'' + property + '\',\n' +
      '    ' + prototype + '.' + property + ');\n';
}
 
 
/**
 * Generate export code given a list symbol names.
 * @param {Array.<Object>} symbols List of symbols.
 * @param {string|undefined} namespace Target object for exported symbols.
 * @param {Array.<string>} provides List of all provides.
 * @return {string} Export code.
 */
function generateExports(symbols, namespace, provides) {
  var blocks = [];
  provides.forEach(function(provide) {
    blocks.push('goog.require(\'' + provide + '\');');
  });
  blocks.push('\n\n');
  symbols.forEach(function(symbol) {
    var name = symbol.name;
    if (name.indexOf('#') > 0) {
      blocks.push(formatPropertyExport(name));
    } else {
      blocks.push(formatSymbolExport(name, namespace));
    }
  });
  blocks.unshift(
      '/**\n' +
      ' * @fileoverview Custom exports file.\n' +
      ' * @suppress {checkVars,extraRequire}\n' +
      ' */\n');
  return blocks.join('\n');
}
 
 
/**
 * Generate the exports code.
 *
 * @param {Object} config Config object with exports and (optional) namespace.
 * @param {function(Error, string)} callback Called with the exports code or any
 *     error generating it.
 */
function main(config, callback) {
  async.waterfall([
    getSymbols.bind(null, config.exports),
    filterSymbols,
    function(symbols, provides, done) {
      var code, err;
      try {
        code = generateExports(symbols, config.namespace, provides);
      } catch (e) {
        err = e;
      }
      done(err, code);
    }
  ], callback);
}
 
 
/**
 * If running this module directly, read the config file, call the main
 * function, and write the output file.
 */
Iif (require.main === module) {
  var options = nomnom.options({
    output: {
      position: 0,
      required: true,
      help: 'Output file path'
    },
    config: {
      abbr: 'c',
      help: 'Path to JSON config file',
      metavar: 'CONFIG'
    }
  }).parse();
 
  async.waterfall([
    getConfig.bind(null, options.config),
    main,
    fs.outputFile.bind(fs, options.output)
  ], function(err) {
    if (err) {
      process.stderr.write(err.message + '\n');
      process.exit(1);
    } else {
      process.exit(0);
    }
  });
}
 
 
/**
 * Export main function.
 */
module.exports = main;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/generate-externs.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/generate-externs.js

Statements: 12.84% (14 / 109)      Branches: 2.27% (1 / 44)      Functions: 0% (0 / 15)      Lines: 12.84% (14 / 109)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 2301 1 1   1   1             1                                         1           1                                   1                   1               1                                                                                                                                                                                                                 1                                       1                                                   1    
var async = require('async');
var fs = require('fs-extra');
var nomnom = require('nomnom');
 
var generateInfo = require('./generate-info');
 
var googRegEx = /^goog\..*$/;
 
/**
 * Read the symbols from info file.
 * @param {function(Error, Array.<string>, Array.<Object>)} callback Called
 *     with the patterns and symbols (or any error).
 */
function getInfo(callback) {
  generateInfo(function(err) {
    if (err) {
      callback(new Error('Trouble generating info: ' + err.message));
      return;
    }
    var info = require('../build/info.json');
    callback(null, info.typedefs, info.symbols, info.externs, info.base);
  });
}
 
 
/**
 * Generate externs code given a list symbols.
 * @param {Array.<Object>} typedefs List of typedefs.
 * @param {Array.<Object>} symbols List of symbols.
 * @param {Array.<Object>} externs List of externs.
 * @param {Array.<Object>} base List of base.
 * @param {string|undefined} namespace Target object for exported symbols.
 * @return {string} Export code.
 */
function generateExterns(typedefs, symbols, externs, base) {
  var lines = [];
  var processedSymbols = {};
  var constructors = {};
  var constructorOptionsTypes = {};
 
  function addNamespaces(name) {
    var parts = name.split('.');
    parts.pop();
    var namespace = [];
    parts.forEach(function(part) {
      namespace.push(part);
      var partialNamespace = namespace.join('.');
      if (!(partialNamespace in processedSymbols ||
          partialNamespace in constructors)) {
        lines.push('/**');
        lines.push(' * @type {Object}');
        lines.push(' */');
        lines.push(nameToJS(partialNamespace) + ';');
        lines.push('\n');
      }
    });
  }
 
  function nameToJS(name) {
    processedSymbols[name] = true;
    if (name.indexOf('.') === -1) {
      name = 'var ' + name;
    }
    return name;
  }
 
  // Store in "constructorOptionsTypes" type names that start
  // with "ol." and end with "Options".
  function findConstructorOptionsTypes(types) {
    types.forEach(function(type) {
      if (type.match(/^ol\..*Options$/)) {
        constructorOptionsTypes[type] = true;
      }
    });
  }
 
  function processSymbol(symbol) {
    addNamespaces(symbol.name.split('#')[0]);
 
    var name = symbol.name;
    if (name.indexOf('#') > 0) {
      name = symbol.name.replace('#', '.prototype.');
      var constructor = symbol.name.split('#')[0];
      if (!(constructor in constructors)) {
        constructors[constructor] = true;
        lines.push('/**');
        lines.push(' * @constructor');
        lines.push(' */');
        lines.push(nameToJS(constructor) + ' = function() {};');
        lines.push('\n');
      }
    }
 
    lines.push('/**');
    if (symbol.kind === 'class') {
      constructors[name] = true;
      lines.push(' * @constructor');
      if (symbol.extends && !googRegEx.test(symbol.extends)) {
        lines.push(' * @extends {' + symbol.extends + '}');
      }
    }
    if (symbol.types) {
      lines.push(' * @type {' + symbol.types.join('|') + '}');
    }
    var args = [];
    if (symbol.params) {
      symbol.params.forEach(function(param) {
        findConstructorOptionsTypes(param.types);
        args.push(param.name);
        lines.push(' * @param {' +
            (param.variable ? '...' : '') +
            param.types.join('|') +
            (param.optional ? '=' : '') + (param.nullable ? '!' : '') +
            '} ' + param.name);
      });
    }
    if (symbol.returns) {
      lines.push(' * @return {' +
          (symbol.returns.nullable ? '!' : '') +
          symbol.returns.types.join('|') + '}');
    }
    if (symbol.template) {
      lines.push(' * @template ' + symbol.template);
    }
    lines.push(' */');
    if (symbol.kind === 'function' || symbol.kind === 'class') {
      lines.push(nameToJS(name) + ' = function(' + args.join(', ') + ') {};');
    } else {
      lines.push(nameToJS(name) + ';');
    }
    lines.push('\n');
  }
 
  externs.forEach(processSymbol);
 
  base.forEach(processSymbol);
 
  symbols.forEach(processSymbol);
 
  typedefs.forEach(function(typedef) {
    // we're about to add a @typedef for "typedef.name" so remove that
    // type from constructorOptionsTypes
    delete constructorOptionsTypes[typedef.name];
 
    addNamespaces(typedef.name);
    lines.push('/**');
    lines.push(' * @typedef {' + typedef.types.join('|') + '}');
    lines.push(' */');
    lines.push(nameToJS(typedef.name) + ';');
    lines.push('\n');
  });
 
 
  // At this point constructorOptionsTypes includes options types for which we
  // did not have a @typedef yet. For those we add @typedef {Object}.
  //
  // This is used for abstract base classes. Abstract base classes should be
  // defined as types in the ol externs file. But the corresponding @typedef's
  // are not marked with an @api annotation because abstract base classes are
  // not instantiated by applications. Yet, we need to have a type defined
  // in the ol externs file for these options types. So we just use
  // @typedef {Object}.
  Object.keys(constructorOptionsTypes).forEach(function(key) {
    lines.push('/**');
    lines.push(' * No `@api` annotation for `' + key + '`, use `Object`.');
    lines.push(' * @typedef {Object}');
    lines.push(' */');
    lines.push(nameToJS(key) + ';');
    lines.push('\n');
  });
 
  return lines.join('\n');
}
 
 
/**
 * Generate the exports code.
 *
 * @param {function(Error, string)} callback Called with the exports code or any
 *     error generating it.
 */
function main(callback) {
  async.waterfall([
    getInfo,
    function(typedefs, symbols, externs, base, done) {
      var code, err;
      try {
        code = generateExterns(typedefs, symbols, externs, base);
      } catch (e) {
        err = e;
      }
      done(err, code);
    }
  ], callback);
}
 
 
/**
 * If running this module directly, read the config file, call the main
 * function, and write the output file.
 */
Iif (require.main === module) {
  var options = nomnom.options({
    output: {
      position: 0,
      required: true,
      help: 'Output path for the generated externs file.'
    }
  }).parse();
 
  async.waterfall([
    main,
    fs.outputFile.bind(fs, options.output)
  ], function(err) {
    if (err) {
      process.stderr.write(err.message + '\n');
      process.exit(1);
    } else {
      process.exit(0);
    }
  });
}
 
 
/**
 * Export main function.
 */
module.exports = main;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/generate-info.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/generate-info.js

Statements: 23.88% (32 / 134)      Branches: 8.7% (4 / 46)      Functions: 3.33% (1 / 30)      Lines: 23.88% (32 / 134)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 3241 1 1   1 1 1   1 1 1       1             1 1       1 1         1 2 2 1             1   1                 1                                           1                                                         1                                                                             1                                                         1                                                                                       1                                               1               1                                             1                                     1                               1                             1    
var fs = require('fs-extra');
var path = require('path');
var spawn = require('child_process').spawn;
 
var async = require('async');
var walk = require('walk').walk;
var isWindows = process.platform.indexOf('win') === 0;
 
var sourceDir = path.join(__dirname, '..', 'src');
var externsDir = path.join(__dirname, '..', 'externs');
var externsPaths = [
  path.join(externsDir, 'olx.js'),
  path.join(externsDir, 'geojson.js')
];
var infoPath = path.join(__dirname, '..', 'build', 'info.json');
 
/**
 * Get checked path of a binary.
 * @param {string} binaryName Binary name of the binary path to find.
 * @return {string} Path.
 */
function getBinaryPath(binaryName) {
  Iif (isWindows) {
    binaryName += '.cmd';
  }
 
  var jsdocResolved = require.resolve('jsdoc/jsdoc.js');
  var expectedPaths = [
    path.join(__dirname, '..', 'node_modules', '.bin', binaryName),
    path.resolve(path.join(path.dirname(jsdocResolved), '..', '.bin', binaryName))
  ];
 
  for (var i = 0; i < expectedPaths.length; i++) {
    var expectedPath = expectedPaths[i];
    if (fs.existsSync(expectedPath)) {
      return expectedPath;
    }
  }
 
  throw Error('JsDoc binary was not found in any of the expected paths: ' + expectedPaths);
}
 
var jsdoc = getBinaryPath('jsdoc');
 
var jsdocConfig = path.join(
    __dirname, '..', 'config', 'jsdoc', 'info', 'conf.json');
 
 
/**
 * Get the mtime of the info file.
 * @param {function(Error, Date)} callback Callback called with any
 *     error and the mtime of the info file (zero date if it doesn't exist).
 */
function getInfoTime(callback) {
  fs.stat(infoPath, function(err, stats) {
    if (err) {
      if (err.code === 'ENOENT') {
        callback(null, new Date(0));
      } else {
        callback(err);
      }
    } else {
      callback(null, stats.mtime);
    }
  });
}
 
 
/**
 * Test whether any externs are newer than the provided date.
 * @param {Date} date Modification time of info file.
 * @param {function(Error, Date, boolen)} callback Called with any
 *     error, the mtime of the info file (zero date if it doesn't exist), and
 *     whether any externs are newer than that date.
 */
function getNewerExterns(date, callback) {
  var newer = false;
  var walker = walk(externsDir);
  walker.on('file', function(root, stats, next) {
    var sourcePath = path.join(root, stats.name);
    externsPaths.forEach(function(path) {
      if (sourcePath === path && stats.mtime > date) {
        newer = true;
      }
    });
    next();
  });
  walker.on('errors', function() {
    callback(new Error('Trouble walking ' + externsDir));
  });
  walker.on('end', function() {
    callback(null, date, newer);
  });
}
 
 
/**
 * Generate a list of all .js paths in the source directory if any are newer
 * than the provided date.
 * @param {Date} date Modification time of info file.
 * @param {boolean} newer Whether any externs are newer than date.
 * @param {function(Error, Array.<string>)} callback Called with any
 *     error and the array of source paths (empty if none newer).
 */
function getNewer(date, newer, callback) {
  var paths = [].concat(externsPaths);
 
  var walker = walk(sourceDir);
  walker.on('file', function(root, stats, next) {
    var sourcePath = path.join(root, stats.name);
    if (/\.js$/.test(sourcePath)) {
      paths.push(sourcePath);
      if (stats.mtime > date) {
        newer = true;
      }
    }
    next();
  });
  walker.on('errors', function() {
    callback(new Error('Trouble walking ' + sourceDir));
  });
  walker.on('end', function() {
 
    /**
     * Windows has restrictions on length of command line, so passing all the
     * changed paths to a task will fail if this limit is exceeded.
     * To get round this, if this is Windows and there are newer files, just
     * pass the sourceDir to the task so it can do the walking.
     */
    if (isWindows) {
      paths = [sourceDir].concat(externsPaths);
    }
 
    callback(null, newer ? paths : []);
  });
}
 
 
/**
 * Parse the JSDoc output.
 * @param {string} output JSDoc output
 * @return {Object} Symbol and define info.
 */
function parseOutput(output) {
  if (!output) {
    throw new Error('Expected JSON output');
  }
 
  var info;
  try {
    info = JSON.parse(String(output));
  } catch (err) {
    throw new Error('Failed to parse output as JSON: ' + output);
  }
  if (!Array.isArray(info.symbols)) {
    throw new Error('Expected symbols array: ' + output);
  }
  if (!Array.isArray(info.defines)) {
    throw new Error('Expected defines array: ' + output);
  }
 
  return info;
}
 
 
/**
 * Spawn JSDoc.
 * @param {Array.<string>} paths Paths to source files.
 * @param {function(Error, string)} callback Callback called with any error and
 *     the JSDoc output (new metadata).  If provided with an empty list of paths
 *     the callback will be called with null.
 */
function spawnJSDoc(paths, callback) {
  if (paths.length === 0) {
    process.nextTick(function() {
      callback(null, null);
    });
    return;
  }
 
  var output = '';
  var errors = '';
  var cwd = path.join(__dirname, '..');
  var child = spawn(jsdoc, ['-c', jsdocConfig].concat(paths), {cwd: cwd});
 
  child.stdout.on('data', function(data) {
    output += String(data);
  });
 
  child.stderr.on('data', function(data) {
    errors += String(data);
  });
 
  child.on('exit', function(code) {
    if (code) {
      callback(new Error(errors || 'JSDoc failed with no output'));
    } else {
      var info;
      try {
        info = parseOutput(output);
      } catch (err) {
        callback(err);
        return;
      }
      callback(null, info);
    }
  });
}
 
 
/**
 * Given the path to a source file, get the list of provides.
 * @param {string} srcPath Path to source file.
 * @param {function(Error, Array.<string>)} callback Called with a list of
 *     provides or any error.
 */
var getProvides = async.memoize(function(srcPath, callback) {
  fs.readFile(srcPath, function(err, data) {
    if (err) {
      callback(err);
      return;
    }
    var provides = [];
    var matcher = /goog\.provide\('(.*)'\)/;
    String(data).split('\n').forEach(function(line) {
      var match = line.match(matcher);
      if (match) {
        provides.push(match[1]);
      }
    });
    callback(null, provides);
  });
});
 
 
/**
 * Add provides data to new symbols.
 * @param {Object} info Symbols and defines metadata.
 * @param {function(Error, Object)} callback Updated metadata.
 */
function addSymbolProvides(info, callback) {
  if (!info) {
    process.nextTick(function() {
      callback(null, null);
    });
    return;
  }
 
  function addProvides(symbol, callback) {
    getProvides(symbol.path, function(err, provides) {
      if (err) {
        callback(err);
        return;
      }
      symbol.provides = provides;
      callback(null, symbol);
    });
  }
 
  async.map(info.symbols, addProvides, function(err, newSymbols) {
    info.symbols = newSymbols;
    callback(err, info);
  });
}
 
 
/**
 * Write symbol and define metadata to the info file.
 * @param {Object} info Symbol and define metadata.
 * @param {function(Error)} callback Callback.
 */
function writeInfo(info, callback) {
  if (info) {
    var str = JSON.stringify(info, null, '  ');
    fs.outputFile(infoPath, str, callback);
  } else {
    process.nextTick(function() {
      callback(null);
    });
  }
}
 
 
/**
 * Determine if source files have been changed, run JSDoc and write updated
 * info if there are any changes.
 *
 * @param {function(Error)} callback Called when the info file has been written
 *     (or an error occurs).
 */
function main(callback) {
  async.waterfall([
    getInfoTime,
    getNewerExterns,
    getNewer,
    spawnJSDoc,
    addSymbolProvides,
    writeInfo
  ], callback);
}
 
 
/**
 * If running this module directly, read the config file and call the main
 * function.
 */
Iif (require.main === module) {
  main(function(err) {
    if (err) {
      process.stderr.write(err.message + '\n');
      process.exit(1);
    } else {
      process.exit(0);
    }
  });
}
 
 
/**
 * Export main function.
 */
module.exports = main;
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/generate-requires.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/generate-requires.js

Statements: 82.35% (14 / 17)      Branches: 62.5% (5 / 8)      Functions: 75% (3 / 4)      Lines: 82.35% (14 / 17)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 421     1           1   1   2 1     1 1       1   1 196 196         1 1                  
var fs = require('fs-extra');
 
// The number of files that we need to generate goog.require's for.
var numFiles = process.argv.length - 1;
 
/**
 * Object used a set of found goog.provide's.
 * @type {Object.<string, boolean>}
 */
var requires = {};
 
process.argv.forEach(function(val, index, array) {
 
  if (index === 0) {
    return;
  }
 
  fs.readFile(val, function(err, data) {
    Iif (err) {
      return;
    }
 
    var re = new RegExp('goog\\.provide\\(\'(.*)\'\\);');
 
    data.toString().split('\n').forEach(function(line) {
      var match = line.match(re);
      Iif (match) {
        requires[match[1]] = true;
      }
    });
 
    Eif (--numFiles === 0) {
      Object.keys(requires).sort().forEach(function(key) {
        process.stdout.write('goog.require(\'' + key + '\');\n');
      });
    }
 
  });
 
});
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/install.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/install.js

Statements: 66.67% (4 / 6)      Branches: 50% (1 / 2)      Functions: 100% (1 / 1)      Lines: 66.67% (4 / 6)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 121   1 1       1        
var buildExt = require('./build-ext');
 
buildExt(function(err) {
  Iif (err) {
    process.stderr.write(err + '\n');
    process.exit(1);
  } else {
    process.exit(0);
  }
});
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/serve-lib.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/serve-lib.js

Statements: 20.93% (9 / 43)      Branches: 8.33% (1 / 12)      Functions: 0% (0 / 9)      Lines: 20.93% (9 / 43)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115          1   1 1   1 1           1                                                               1 1                                                 1                                                                              
/**
 * This task starts a dev server that provides a script loader for the
 * OpenLayers library.
 */
 
var path = require('path');
 
var closure = require('closure-util');
var nomnom = require('nomnom');
 
var log = closure.log;
var name = path.basename(__filename, '.js');
 
/**
 * Create a debug server for the OpenLayers and Closure Library sources.
 * @param {function(Error, closure.Server)} callback Callback.
 */
var createServer = exports.createServer = function(callback) {
  var server;
  var manager = new closure.Manager({
    lib: [
      'src/**/*.js',
      'build/ol.ext/*.js'
    ],
    cwd: path.join(__dirname, '..')
  });
  manager.on('error', function(err) {
    if (server) {
      log.error('serve', err.message);
    } else {
      callback(err);
    }
  });
  manager.on('ready', function() {
    server = new closure.Server({
      manager: manager,
      loader: '/loader.js'
    });
    callback(null, server);
  });
};
 
/**
 * Try listening for incoming connections on a range of ports.
 * @param {number} min Minimum port to try.
 * @param {number} max Maximum port to try.
 * @param {http.Server} server The server.
 * @param {function(Error)} callback Callback called with any error.
 */
function listen(min, max, server, callback) {
  function _listen(port) {
    server.once('error', function(err) {
      if (err.code === 'EADDRINUSE') {
        log.warn(name, 'Port %d in use, trying next one', port);
        ++port;
        if (port < max) {
          _listen(port);
        } else {
          callback(new Error('Could not find an open port'));
        }
      } else {
        callback(err);
      }
    });
    server.listen(port);
  }
  server.once('listening', function() {
    callback(null);
  });
  _listen(min);
}
 
/**
 * If running this module directly start the server.
 */
Iif (require.main === module) {
  var options = nomnom.options({
    port: {
      abbr: 'p',
      default: 3000,
      help: 'Port for incoming connections (will try additional ports if used)',
      metavar: 'PORT'
    },
    loglevel: {
      abbr: 'l',
      choices: ['silly', 'verbose', 'info', 'warn', 'error'],
      default: 'info',
      help: 'Log level',
      metavar: 'LEVEL'
    }
  }).parse();
 
  /** @type {string} */
  log.level = options.loglevel;
 
  log.info(name, 'Parsing dependencies.');
  createServer(function(err, server) {
    if (err) {
      log.error(name, 'Parsing failed');
      log.error(name, err.message);
      process.exit(1);
    }
    listen(options.port, options.port + 4, server, function(err) {
      if (err) {
        log.error(name, 'Server failed to start: ' + err.message);
        process.exit(1);
      }
      log.info(name, 'Debug server running http://localhost:' +
          server.address().port + '/loader.js (Ctrl+C to stop)');
    });
  });
 
}
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/serve.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/tasks/serve.js

Statements: 8.22% (6 / 73)      Branches: 0% (0 / 20)      Functions: 0% (0 / 12)      Lines: 8.22% (6 / 73)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160            2 2   2 2 2                                                                                                                                     1                                                                                                                                                                  
/**
 * This task starts a dev server that provides a script loader for OpenLayers
 * and Closure Library.  In addition, a static server hosts all files in the
 * repository.
 */
 
var path = require('path');
var url = require('url');
 
var Gaze = require('gaze').Gaze;
var closure = require('closure-util');
var debounce = require('debounce');
var fs = require('fs-extra');
var nomnom = require('nomnom');
 
var buildExamples = require('./build-examples');
var log = closure.log;
 
 
/**
 * Create a debug server for ol and Closure Library sources.
 * @param {function(Error, closure.Server)} callback Callback.
 */
var createServer = exports.createServer = function(callback) {
  var server;
  var manager = new closure.Manager({
    lib: [
      'src/**/*.js',
      'build/ol.ext/*.js',
      'test/spec/**/*.test.js',
      'test_rendering/spec/**/*.test.js',
      'build/test_requires.js',
      'build/test_rendering_requires.js'
    ],
    main: 'build/examples/*.js'
  });
  manager.on('error', function(err) {
    if (server) {
      log.error('serve', err.message);
    } else {
      callback(err);
    }
  });
  manager.on('ready', function() {
    server = new closure.Server({
      manager: manager,
      loader: /^\/(?:(?:build\/examples)|(?:test(?:_rendering)?))\/loader\.js/,
      getMain: function(req) {
        var main;
        var query = url.parse(req.url, true).query;
        var referer = req.headers.referer;
        var pathName = url.parse(referer).pathname;
        if (pathName.indexOf('/test/') === 0) {
          main = path.resolve(
            path.join(process.cwd(), 'build'), 'test_requires.js');
        } else if (pathName.indexOf('/test_rendering/') === 0) {
          main = path.resolve(
            path.join(process.cwd(), 'build'), 'test_rendering_requires.js');
        } else {
          if (query.id) {
            if (referer) {
              var from = path.join(process.cwd(),
                  path.dirname(url.parse(referer).pathname));
              main = path.resolve(from, query.id + '.js');
            }
          }
        }
        return main;
      }
    });
    callback(null, server);
  });
};
 
/**
 * Build the examples and exit on any error.
 * @param {Function=} opt_callback Called when done building examples.
 */
function buildExamplesOrFatal(opt_callback) {
  log.info('serve', 'Building examples.');
  buildExamples(function(err) {
    if (err) {
      log.error('serve', 'Building examples failed.');
      log.error('serve', err.message);
      log.error('serve', 'Use "verbose" logging to see the full stack trace.');
      log.verbose('serve', err.stack);
      process.exit(1);
    }
    // This is awkward, but then so is CSS itself
    var src = path.join(__dirname, '..', 'css', 'ol.css');
    var dest = path.join(__dirname, '..', 'build', 'css', 'ol.css');
    fs.copy(src, dest, function(err2) {
      if (err2) {
        log.error('serve', 'Failed to copy CSS.');
        log.error('serve', err.message);
        log.error('serve',
            'Use "verbose" logging to see the full stack trace.');
        log.verbose('serve', err.stack);
        process.exit(1);
      }
      log.verbose('serve', 'Done building examples.');
      if (opt_callback) {
        opt_callback();
      }
    });
  });
}
 
/**
 * If running this module directly start the server.
 */
if (require.main === module) {
  var options = nomnom.options({
    port: {
      abbr: 'p',
      default: 3000,
      help: 'Port for incoming connections',
      metavar: 'PORT'
    },
    loglevel: {
      abbr: 'l',
      choices: ['silly', 'verbose', 'info', 'warn', 'error'],
      default: 'info',
      help: 'Log level',
      metavar: 'LEVEL'
    }
  }).parse();
 
  /** @type {string} */
  log.level = options.loglevel;
 
  buildExamplesOrFatal(function() {
    log.info('serve', 'Parsing dependencies.');
    createServer(function(err, server) {
      if (err) {
        log.error('serve', 'Parsing failed');
        log.error('serve', err.message);
        process.exit(1);
      }
      server.listen(options.port, function() {
        log.info('serve', 'Listening on http://localhost:' +
            options.port + '/ (Ctrl+C to stop)');
      });
      server.on('error', function(err) {
        log.error('serve', 'Server failed to start: ' + err.message);
        process.exit(1);
      });
    });
 
    var gaze = new Gaze('examples/**/*');
    var debouncedBuild = debounce(buildExamplesOrFatal, 250);
    gaze.on('all', function(event, filepath) {
      log.verbose('serve', 'Watch event: ' + event + ' ' + filepath);
      debouncedBuild();
    });
  });
 
}
 
 
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/transforms/

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/transforms/

Statements: 11.83% (11 / 93)      Branches: 0% (0 / 30)      Functions: 0% (0 / 7)      Lines: 11.83% (11 / 93)      Ignored: none     

All files » node-npmtest-openlayers/node_modules/openlayers/transforms/
File Statements Branches Functions Lines
module.js 11.83% (11 / 93) 0% (0 / 30) 0% (0 / 7) 11.83% (11 / 93)
Code coverage report for node-npmtest-openlayers/node_modules/openlayers/transforms/module.js

npmtest-openlayers (v0.0.1)

Code coverage report for node-npmtest-openlayers/node_modules/openlayers/transforms/module.js

Statements: 11.83% (11 / 93)      Branches: 0% (0 / 30)      Functions: 0% (0 / 7)      Lines: 11.83% (11 / 93)      Ignored: none     

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 2231 1   1       1         1                                                                             1                                       1                     1 1                                         1                   1                                                                                                                                                                                                                        
const pkg = require('../package.json');
const version = require('../package/package.json').version;
 
const defines = {
  'ol.ENABLE_WEBGL': false
};
 
function rename(name) {
  const parts = name.split('.');
  return `_${parts.join('_')}_`;
}
 
function resolve(fromName, toName) {
  const fromParts = fromName.split('.');
  const toParts = toName.split('.');
  if (toParts[0] === 'ol' && toParts[1] === 'ext') {
    let name = toParts[2];
    let packageName;
    for (let i = 0, ii = pkg.ext.length; i < ii; ++i) {
      const dependency = pkg.ext[i];
      if (dependency.module === name) {
        packageName = name;
        break;
      } else if (dependency.name === name) {
        packageName = dependency.module;
        break;
      }
    }
    if (!packageName) {
      throw new Error(`Can't find package name for ${toName}`);
    }
    return packageName;
  }
  const fromLength = fromParts.length;
  let commonDepth = 1;
  while (commonDepth < fromLength - 2) {
    if (fromParts[commonDepth] === toParts[commonDepth]) {
      ++commonDepth;
    } else {
      break;
    }
  }
 
  const back = new Array(fromLength - commonDepth).join('../') || './';
  let relative = back + toParts.slice(commonDepth).join('/').toLowerCase();
  if (relative.endsWith('/')) {
    relative += 'index';
  }
  return relative;
}
 
function getGoogExpressionStatement(identifier) {
  return {
    type: 'ExpressionStatement',
    expression: {
      type: 'CallExpression',
      callee: {
        type: 'MemberExpression',
        object: {
          type: 'Identifier',
          name: 'goog'
        },
        property: {
          type: 'Identifier',
          name: identifier
        }
      }
    }
  };
}
 
const defineMemberExpression = {
  type: 'MemberExpression',
  object: {
    type: 'Identifier',
    name: 'ol'
  },
  property: {
    type: 'Identifier'
  }
};
 
function getMemberExpression(name) {
  function memberExpression(parts) {
    const dotIndex = parts.lastIndexOf('.');
    if (dotIndex > 0) {
      return {
        type: 'MemberExpression',
        object: memberExpression(parts.slice(0, dotIndex)),
        property: {
          type: 'Identifier',
          name: parts.slice(dotIndex + 1)
        }
      };
    } else {
      return {
        type: 'Identifier',
        name: parts
      };
    }
  }
  return memberExpression(name);
}
 
function getMemberExpressionAssignment(name) {
  return {
    type: 'ExpressionStatement',
    expression: {
      type: 'AssignmentExpression',
      left: getMemberExpression(name)
    }
  };
}
 
module.exports = function(info, api) {
  const j = api.jscodeshift;
  const root = j(info.source);
 
  // store any initial comments
  const {comments} = root.find(j.Program).get('body', 0).node;
 
  // replace `ol.VERSION = ''` with correct version
  root.find(j.ExpressionStatement, getMemberExpressionAssignment('ol.VERSION'))
    .forEach(path => {
      path.value.expression.right = j.literal(version);
    });
 
  const replacements = {};
 
  // replace all uses of defines
  root.find(j.MemberExpression, defineMemberExpression)
    .filter(path => {
      const node = path.value;
      const name = `${node.object.name}.${node.property.name}`;
      return (name in defines) && path.parentPath.value.type !== 'AssignmentExpression';
    })
    .replaceWith(path => {
      const name = `${path.value.object.name}.${path.value.property.name}`;
      return j.literal(defines[name]);
    });
 
  // remove goog.provide()
  let provide;
  root.find(j.ExpressionStatement, getGoogExpressionStatement('provide'))
    .forEach(path => {
      if (provide) {
        throw new Error(`Multiple provides in ${info.path}`);
      }
      provide = path.value.expression.arguments[0].value;
    }).remove();
 
  if (!provide) {
    throw new Error(`No provide found in ${info.path}`);
  }
  replacements[provide] = rename(provide);
 
  // replace provide assignment with variable declarator
  // e.g. `ol.foo.Bar = function() {}` -> `var _ol_foo_Bar_ = function() {}`
  let declaredProvide = false;
  root.find(j.ExpressionStatement, getMemberExpressionAssignment(provide))
    .replaceWith(path => {
      declaredProvide = true;
      const statement = j.variableDeclaration('var', [
        j.variableDeclarator(j.identifier(rename(provide)), path.value.expression.right)
      ]);
      statement.comments = path.value.comments;
      return statement;
    });
 
  if (!declaredProvide) {
    const body = root.find(j.Program).get('body');
    body.unshift(
      j.variableDeclaration('var', [
        j.variableDeclarator(j.identifier(rename(provide)), j.objectExpression([]))
      ])
    );
  }
 
  // replace `goog.require('foo')` with `import foo from 'foo'`
  const imports = [];
  root.find(j.ExpressionStatement, getGoogExpressionStatement('require'))
    .forEach(path => {
      const name = path.value.expression.arguments[0].value;
      if (name in replacements) {
        throw new Error(`Duplicate require found in ${info.path}: ${name}`);
      }
      const renamed = rename(name);
      replacements[name] = renamed;
      imports.push(
        j.importDeclaration(
          [j.importDefaultSpecifier(j.identifier(renamed))],
          j.literal(resolve(provide, name))
        )
      );
    })
    .remove();
 
  const body = root.find(j.Program).get('body');
  body.unshift.apply(body, imports);
 
  // replace all uses of required or provided names with renamed identifiers
  Object.keys(replacements).sort().reverse().forEach(name => {
    if (name.indexOf('.') > 0) {
      root.find(j.MemberExpression, getMemberExpression(name))
        .replaceWith(j.identifier(replacements[name]));
    } else {
      root.find(j.Identifier, {name: name})
        .replaceWith(j.identifier(replacements[name]));
    }
  });
 
  // add export declaration
  root.find(j.Program).get('body').push(
    j.exportDefaultDeclaration(j.identifier(rename(provide)))
  );
 
  // replace any initial comments
  root.get().node.comments = comments;
 
  return root.toSource({quote: 'single'});
};